Posts Categorized: linux

Tunnel Web Browsing to Remote Server over SSH

So I want to be able to test web access from outside our network. On my private server I have Squid running on port 3128 so: ssh -L 3128:localhost:3128 jonny@myprivateserver.com Then I can configure Firefox (with FoxyProxy) to use localhost port 3128 as a proxy. Then on the private server tail the squid access log… Read more »

Blocking Attackers in ProFTPd

To manually block an IP address accessing ProFTPd you can use the following in the ProFTPd config file: <Limit LOGIN>Order deny,allowDeny from 111.222.111.222Allow from all</Limit></Global> Of course it would be better to use IPtables iptables -A INPUT -s 111.222.111.222 -j DROP To allow the IP address again: iptables -D INPUT -s 111.222.111.222 -j DROP Where… Read more »

Convert bin/cue to iso with bchunk

On Ubuntu install binchunker with: sudo apt-get install bchunk Then create the iso at the command-line with the following: bchunk myfile.bin myfile.cue newfile.iso More info here

Top of the Tops

A roundup of my top top utilities for troubleshooting problems on servers. htopIn terms of alternatives to the traditional top command htop is pretty good (being better than the older atop too). Maybe it is just the colours but it is also useful to get a view of the memory without the caches included. yum… Read more »

Samba Client

Smbclient operates like a command-line ftp client which allows sending commands to the samba server. The following syntax worked for me: /usr/bin/smbclient ‘//anotherserver/myshare’ -D ‘mydirectory/’ -c ‘mkdir “testlog5″‘ -U ‘myusername%mypass’ I got a bit confused when some directories where list with DA rather than D but these extra file attributes appear to be: A –… Read more »

Get iPlayer

The previous version of get_iplayer had stopped working for me but there is still people updating this script. Get it here: http://www.infradead.org/get_iplayer/html/get_iplayer.html

WineTricks for Windows Dependencies

Download the WineTricks script from here: http://wiki.winehq.org/winetricks Make it executable and then move it to /usr/bin or /usr/local/bin Run it and a GUI will appear to tick the stuff you need e.g. 7zip, AdobeAIR, mono, corefonts and many more

VirtualBox Cloning a Virtual Machine

For future reference cp mymachine.vdi mynewmachine.vdi won’t work due o the uuid of the disk so …. cd ~/.VirtualBox/HardDisksVBoxManage clonevdi mymachine.vdi mynewmachine.vdi Then go through the steps of creating a new machine but specify the new vdi image as the disk rather than creating a new one.

Mounting FTP on Ubuntu

Install CurlFtpFS with: sudo apt-get install curlftpfs Mount an FTP site with: sudo curlftpfs -o user=myuser:mypass ftp://ftp.domain.tld ./mylocaldirsudo ls ./mylocaldirsudo fusermount -u ./mylocaldir Or add it to the fstab: mkdir /media/myftpsite && chown myuser:mysuer /media/myftpsitevi /etc/fstab Add the following line at the end of the file: curlftpfs#ftp.domain.tld /media/myftpsite fuse rw,uid=1000,user,noauto 0 0 Then under the… Read more »