Tag Archives: ubuntu

Automated SCP Copy Script (with Wake-On-LAN)

As some of you may know currently I have a file server and a download server. The file server has a script that checks if anyone is connected if not , it goes to sleep. It can be waken via Wake-on-Lan. This is to reduce power consumption , as due to electricity tariffs which are going up in 2014 (that is in Malaysia). My File Server consumes about 60-70W of energy when it is idling. When it is asleep it only consumes about 2W 

server-to-server

My Torrent Server on the other hand consumes about 20W (It’s a little machine that runs on Intel Atom 330) and has a 80GB of Storage. Basically I use it to download things from Deluge.

The problem is that once the file has been downloaded , I would have to move the files manually from my torrent server to my file server . It’s painful – I’ve to ssh over , scp and rm the files once it is done. It is becoming more and more troublesome when you have a large files to copy over – especially downloading movies

ssh [email protected]
cd /downloads/
scp -r file [email protected]:/largeHD/media/
rm file

This is what i generally do . What’s worst is that if my file server is sleeping , I would have to issue a wake on lan command to activate it. Also I’ll have to change the destination every time based on the type of file , as i’ve my file server organised !

Continue reading Automated SCP Copy Script (with Wake-On-LAN)

Samba Wake On Demand Script

Recently , I purchased a raspberry pi and I have to say that it is an amazing device. It now functions as my 24/7 server, however I have already a file server whereby I use to keep important files (such as family vacation photos , important documents , backup of my phone contacts and my save game files if any). The problem was leaving the server 24/7 as it draws about 60W (idle) as opposed to the pi which is about 5W. Of course this could solved by putting the server to sleep and waking it up with a Wake On Lan tool. It’s great if it was me that want to access the shared folder , but how about my less tech savvy family-members

Continue reading Samba Wake On Demand Script

My Server – Part #2

Remember people , that I’ve posted on my blog saying that I’ve received my Server and here is a picture of it. Yeah , its a bit messy but there you have it. The quality isn’t that great as it was taken from a Camera Phone (my old hp hw6515e smartphone which is a 1.3MP Camera) . This is the picture of my Dell OptiPlex GX110 and it runs ubuntu linux. Here are the functions of my server :-

Â

  1. File server – Usually I store my DVD ISOs or some large file there. Despite the 30GB HDD , I still try to make use of every single byte that I’ve. Of course my large files , videos , music all resides in my main PC. I need to find some time to transfer all my music from my pc to my server and then find a way to appear in my iTunes music sharing list. I am sure there is a way. For now let it be like this , once I’ve saved up enough , I’ll get a Hard Disk for my Server (a larger one)
  2. Torrent server – It runs Deluge with WebUI installed , so that I can add torrent , remove torrent by just any web browser. I don’t have to VNC to the server and control it from there , although I am forced to do it when I want to manage my bandwidth (i.e reduce the upload rate and download rate to make way for my online gaming or YouTube streaming)
  3. Web Server and some lame cheap Text-gaming server – A server isn’t complete without a Web Server. So I’ve installed Apache , PHP and MySql in it. Mainly , I wanted to learn more on web scripting and other things. It would be better for me to test it locally then uploading here. It will be a waste of bandwidth and resources and I don’t want to be held responsible if my script hogs bandwidth or contains flaws. The best way to do is test it in Localhost. My server is live by the way – meaning that it can be accessed by anyone on in the Internet but I am not going to post its URL. No , not yet. I’ve to secure it properly first before posting it
So far thats all that I can think of , of course it will be my primary Linux box as well and it will be used to compile programs and other things. I might even start some binary site (compile oss projects , optimise it and then release it) . Oh yeah , the specs you ask :-
*Drums Roll*Â
Dell OptiPlex GX110 - Pentium III (Coppermine) 800 Mhz || 256MB SDRAM 100Mhz || 3Com Corporation 3c905C-TX/TX-M || Realtek Semiconductor Co., Ltd. RTL-8139/8139C/8139C+ || Intel i810 series Board = Intel Corporation 82801AA || SCSI to ATA adapter - ATA Maxtor 2F030L0 || 52x Generic CDROM DriveÂ
There you have it , now stop bugging me and asking me to post my server specs. Oh , nobody asked for it anyway. Just adding spices to make my blog more interesting , thats all !Â
Its My beloved Server - That crunches all the task that I throw at it !
Its My beloved Server - That crunches all the task that I throw at it !