Posts

Showing posts from June, 2014

Octoshape under environment with network proxy

In an environment with network proxy, you have to manually specify the global http and https proxy setting of the system for octoshape to work properly. In Ubuntu, you can find it in All Settings -> Network. Under proxy, manually set the HTTP and HTTPS proxy and click on "Apply system wide".

Linux script to upload files to DropBox and Google drive; send email when there is a new file

1. Linux script to upload file Dropbox See here Google drive Ref: https://gist.github.com/deanet/3427090 You have to update the username and password, and the folderId. folderId can be found from Google Drive URL in your browser. For example, if the Google Drive folder to which you want to upload thing has the following URL: https://drive.google.com/?tab=wo&authuser=0#folders/1234567890AB-CDEFGHIJKLMNOPQR the folderId would be 1234567890AB-CDEFGHIJKLMNOPQR Sample script # Things to update username="xxxx@gmail.com" password="xxxx" pewede="/tmp" tipe="application/x-mobi" folderId="xxxx" OUTFILE2=myfile.mobi accountype="GOOGLE" #gooApps = HOSTED , gmail=GOOGLE   det=`date +%F` browser="Mozilla/5.0 (X11; Ubuntu; Linux i686; rv:13.0) Gecko/20100101 Firefox/13.0.1" /usr/bin/curl -v --data-urlencode Email=$username --data-urlencode Passwd=$password -d accountType=$accountype -d service=writely -d ...

Network for VM under proxy environment

Use bridge networking mode rather than the default NAT. Then the VM is like an additional machine in the local network, and its proxy setting can be configured as any other machine in the network. Reference

Turning wubi installation to VirtualBox virtual machine

Create a new VM in VirtualBox menu. Set up two CD/DVD devices. The first device should mount a Linux Live CD. The other should mount the Guest Addition ISO. You should also put the root.disk to be imported as VirtualBox VM to somewhere in the host OS, and set up "Shared Folder" that points to the respective directory. Boot up the VM and take the "Try" option. When the VM boots up, call gparted and create partitions on the VM harddisk for swap and primary partition. You should get at two /dev/sdax/ devices. Mount the Guest Addition CD and install Guest Addition. Inside the VM, mount the host OS "Shared Folder" that contains root.disk ( Ref ): sudo mount -t vboxsf share ~/host Use the MigrateWubi script to migrate the root.disk content to the VM devices you created above: sudo bash wubi-move.sh --root-disk=/media/win/ubuntu/disks/root.disk /dev/sda1 /dev/sda2