I used Samba when my laptop was Windows, but literally got so frustrated with just about any update in Windows on the laptop forcing a reconfigure, I installed Ubuntu on laptop and then started using NFS. After I posted that a couple of times, someone with more knowledge suggested I use SSH.
https://help.ubuntu.com/12.04/server...sh-server.html
In the menu go accessories > terminal and copy and paste
sudo apt-get install openssh-server openssh-client
Do this on both machines.
But I used NFS and at first it seemed difficult to set up. But once configured I could just run a script to mount partitions & another to rsync folders.
https://help.ubuntu.com/community/SettingUpNFSHowTo
http://mostlylinux.wordpress.com/network/nfshowto/
Scripts I run with new install of Ubuntu to install & configure NFS (inside script so sudo implied)
Code:
#NFS setup
fname_exp=/etc/exports
nfs1="/mnt/data 192.168.1.0/24(rw,no_root_squash,async)"
nfs2="/mnt/shared 192.168.1.0/24(rw,no_root_squash,async)"
echo $nfs1 >> $fname_exp
echo $nfs2 >> $fname_exp
# For NFS /etc/exports already edited rpcbind replaced portmap 12.04
apt-get install nfs-kernel-server nfs-common rpcbind
dpkg-reconfigure rpcbind
exportfs -a
# still portmap?
service portmap restart
Script to Mount my Laptop folders in my Desktop
Code:
#!/bin/bash
# check that exports has been updated and path is correct
#/etc/exports
#/mnt/data 192.168.1.0/24(rw,no_root_squash,async)
#/mnt/shared 192.168.1.0/24(rw,no_root_squash,async)
mkdir /mnt/data_LT
mkdir /mnt/shared_LT
mount 192.168.1.100:/mnt/data /mnt/data_LT
mount 192.168.1.100:/mnt/shared /mnt/shared_LT
Script to rsync
Code:
#!/bin/bash
# run Mount_NFS.sh first
# a - archive, retain file settings
# r - recursive / subdirectories
# u - update, only newer
# v - verbose
# P - keep partial files and report progress
# need to exclude cache from mozilla or houseclean first.
echo "starting..."
rsync -aruvP /mnt/data_LT/Documents /mnt/data
rsync -aruvP /mnt/data_LT/Projects //mnt/data
rsync -aruvP /mnt/data_LT/PDF /mnt/data
Bookmarks