Skip to main content

Posts

Showing posts from August, 2013

Big-O Simplified!

Big-O notation describes patterns of activity of systems in terms of standard mathematical models in which an amount of resources (time, quantity, cost, etc.) determines scope. The patterns of activity must contain input that can be isolated and modified to be improved without negatively effecting the desired outcomes of their systems.  Big-O helps systems analysts describe patterns of activity as best-case, acceptable-case, or worst-case.  Big-O is used in business and computer science for documenting system behavior and for arguing system improvements. Patterns of activity of systems are typically expressed as algorithms. In the simplest terms, b ig-O is an estimate of the optimal efficiency of algorithms. When comparing two or more algorithms for optimal efficiency the following criteria must be met: Algorithms were designed using the same language. Algorithms result in the same measure (e.g. running time). Algorithms use the same set of operations. Algorithms have an est

Uploading files through "shaped" connections without traffic control

Technically shaping is limiting the rate at which packets are sent over a connection. If you want to continue surfing the web or interacting with websites while uploading your files to online storage, you have to find some way to shape your connection to your online storage. Not only will you not be able to interact with websites while uploading files, but your transfer statistics won't be accurate. There are really only two ways you can shape a connection without traffic control. You can either use a relay that supports delaying packets or find some way to slowdown the rate at which your file is sent. In any case, the first thing you have to do is determine how much of your bandwidth you want to dedicate to uploading files. Then you have to convert your bandwidth to a unit measurement that is recognizable by the command rsync. When you're ready you can play with the next command. Here's a one-liner for transferring a file from a remote server via sshd then uploading it

Uploading files through Secure WebDAV using DAVfs

WebDAV is a protocol that facilitates uploading and downloading files through HTTP (port 80) and HTTPS (port 443). Whenever a WebDAV service is being ran over SSL it is called Secure WebDAV. DAVfs is a file system interface to the WebDAV protocol, it works with WebDAV and Secure WebDAV. The command mount uses DAVfs to recognize a WebDAV share as a regular file system so that other tools, scripts, services, and users can access the share's contents (as a file system with actual directories). Here's an easy solution for uploading files to your WebDAV account. These instructions work on Linux, FreeBSD, Solaris, and probably other distributions too. 1. Make a local directory for transferring files. mkdir <your directory>; 2. Stop other processes and users from interfering with your transfers. chown root:root <your directory> && chmod 770 <your directory>; 3. Mount your online cloud share using davfs. Enter your password when the prompt appears askin