Sunday, May 10, 2009

My laptop can access any files in my desktop

After I installed Linux on my laptop, I was able to connect and use any files in my desktop, just like old days with servers. Using SSH, Secure SHell which installed as default, I could connect to desktop and control my work from remote. However, for my laptop to accept connection, I installed openssh-server by typing

sudo apt-get install openssh-server

After that I need to alter configuration file to protect my desktop. By changing the file, /etc/ssh/sshd_config, I could block any other connection except from my laptop. For example, if I uncomment “ListenAddress” and assign only one IP address, I could block virtually all connection attempt from outside. And if I change “PermitRootLogin” to false and add only one user name in “AllowUsers,” I could permit only myself into desktop as non root account. Once I finish my configuration, I could connect my desktop by typing

ssh -l username

After I looked for the path where my game file was located, I could copy the file into my laptop by typing

rcp username@ .

from another terminal in my laptop. Then I decided to watch movie in my desktop folder from my laptop. Because I didn’t want to move movie file into my laptop, I mounted the folder in one of my local folder. To do that, I first installed Secure SHell File System, sshfs, by typing

sshfs username@ ~/mnt

Of course, I needed to create mount point ~/mnt before I mount. I also needed to synchronize some of my folder with my desktop. So I installed Unison both on my laptop and server by typing

apt-get install unison

Additionally, I installed GUI interface for my laptop by typing

apt-get install unison-gtk

After the installation, I ran Union client under “/Applications/Accessories" menu. When Unison ask me to enter root 1 and root 2 folders to sync, I entered one local folder


and one desktop folder name like this


Then the GUI came up and I could synchronize memos. And I don't have to worry about sharing my folder any more.

More information can be found in following URL’s: (For Secure SHell) (Secure SHell File System) (Unison)

No comments:

Post a Comment