LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices

Reply
 
LinkBack Search this Thread
Old 06-20-2012, 11:13 AM   #1
Mark_667
Member
 
Registered: Aug 2005
Location: Manchester, England
Distribution: Ubuntu 12.10
Posts: 257

Rep: Reputation: 25
Writing to NFS share leaves local copy of files


I'm trying to backup an old Solaris system by mounting an NFS share locally and copying files to it. I'd use rsync but it doesn't have it installed and I want to make as few changes as possible. For some reason the files are retained locally at the mount point (even after it's been unmounted) as well as being written to the remote share. Obviously this creates a problem because I can't do a backup without filling up the local disk, why is this?
 
Old 06-20-2012, 12:17 PM   #2
MensaWater
Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 5,774
Blog Entries: 4

Rep: Reputation: 697Reputation: 697Reputation: 697Reputation: 697Reputation: 697Reputation: 697
We'd have to guess since you don't provide details.

A couple of possibilities:

1) The NFS directory is NOT mounted where you think it is. That is just because it is exported as say "/mypath/mydir" from one server does not necessarily mean it has to be mounted as "/mypath/mydir" on the other system - it might be mounted as "/billybob/filesystem". You'd need to show us the /etc/exports from the system you exported it on and the df output on the system you exported it to for us to tell you if we see an issue.

2) You exported a directory that has submounts and/or symbolic links on the exporting server and are trying to write to those submounts on the target server but they don't exist or point to subdirectories that are local to the server you're doing the NFS mount on.
 
Old 06-21-2012, 05:40 AM   #3
Mark_667
Member
 
Registered: Aug 2005
Location: Manchester, England
Distribution: Ubuntu 12.10
Posts: 257

Original Poster
Rep: Reputation: 25
I think I may have solved this. The script I was using used the following command to mount the NFS share:
mount -F nfs -o rw <Windows_backup_server>:/Solaris_Backups/$MachineName /mnt/Backup/
Although the backup server had a directory that corresponded to Solaris_Backups/$MachineName the MachineName subdirectory wasnn't shared, only the parent. It then issued:
mkdir -p /mnt/Backup/$MachineName/$date
(to make the directory if it doesn't already exist) and copied the files to that. Removing $MachineName from the mount command seemed to do it, though I'm still nto sure why it was writing the files lcoally.
 
  


Reply

Tags
backup, nfs


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem while writing files from NFS client to server behind firewall jorisroovers Linux - General 2 01-25-2010 09:40 AM
nfs file share on local host Tom Douglas Linux - Networking 1 10-19-2008 01:44 AM
hang when copy file to nfs share walterwkh Linux - Networking 2 03-05-2008 08:34 PM
share files on local machine bulldogzerofive Linux - General 1 09-16-2005 08:46 AM
nfs / nis problem - slow copy to servermounts but fast from server to local hdd krischeu Linux - Networking 1 06-09-2005 11:05 AM


All times are GMT -5. The time now is 11:58 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration