LinuxQuestions.org
Go Job Hunting at the LQ Job Marketplace
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 03-28-2009, 06:28 PM   #1
crash893
LQ Newbie
 
Registered: Mar 2009
Posts: 6

Rep: Reputation: 0
backup samba share


hey everyone

i have a ubuntu server that is running samba that i recently got the task to administering, and a win 2k3 server i use for IIS

I am using sync back on the win box and the problnem that im running into is that i have to spesify each share

\\server\it , \\server\public, \\server\whatever

and this is okay for a few but i have like 40 user that each have there own share \\share\user and i dont want to have to make changes to the backup each time i do a back up


is there a way to make a "master" folder in samba that has every folder under it \\share\everything

thanks for any help you can shed on this

Crash
 
Old 03-28-2009, 06:47 PM   #2
stress_junkie
Senior Member
 
Registered: Dec 2005
Location: Massachusetts, USA
Distribution: Ubuntu 10.04 and CentOS 5.5
Posts: 3,873

Rep: Reputation: 331Reputation: 331Reputation: 331Reputation: 331
Why are you backing up over the network? Wouldn't it be easier just to back up the Ubuntu server?
 
Old 03-28-2009, 07:53 PM   #3
jschiwal
Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 654Reputation: 654Reputation: 654Reputation: 654Reputation: 654Reputation: 654
do these shares have a common subdirectory?
You could configure samba like a home share:
Code:
[homes]
        comment = Home Directories
        valid users = %S, %D%w%S
        browseable = No
        read only = No
        inherit acls = Yes
        invalid users = root
        read list = root
You would need to check that the permissions of the users directories aren't too permissive with respect to other users getting access. Also, if you have a large number of users, they would have to locate their directory from a large list. In a [Profile] type share, only the contents of the user's own directory is present when they open it.

It might be better of you offered the parent directory as an nfs share, that a backup operator has access to, and backed it up instead. This would mean running Linux or Unix on the backup machine.

I don't know it it would be cosher to have for example: /srv/samba/user1, /srv/samba/user2, ... , /srv/samba offered, but if it is you could have
 
Old 03-30-2009, 09:50 AM   #4
crash893
LQ Newbie
 
Registered: Mar 2009
Posts: 6

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by jschiwal View Post
do these shares have a common subdirectory?
You could configure samba like a home share:
Code:
[homes]
        comment = Home Directories
        valid users = %S, %D%w%S
        browseable = No
        read only = No
        inherit acls = Yes
        invalid users = root
        read list = root
You would need to check that the permissions of the users directories aren't too permissive with respect to other users getting access. Also, if you have a large number of users, they would have to locate their directory from a large list. In a [Profile] type share, only the contents of the user's own directory is present when they open it.

It might be better of you offered the parent directory as an nfs share, that a backup operator has access to, and backed it up instead. This would mean running Linux or Unix on the backup machine.

I don't know it it would be cosher to have for example: /srv/samba/user1, /srv/samba/user2, ... , /srv/samba offered, but if it is you could have
the nfs part sounds like it might work

that leaves me with 2 questions

1) where is the default location for teh samba parrent dir

2) how would i then share it

sorry to ask so much but i litterly started using samaba (and thus unbuntu) a few days ago so its all pretty new to me.
 
Old 03-31-2009, 10:01 AM   #5
crash893
LQ Newbie
 
Registered: Mar 2009
Posts: 6

Original Poster
Rep: Reputation: 0
Bump
 
Old 04-01-2009, 07:17 PM   #6
jschiwal
Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 654Reputation: 654Reputation: 654Reputation: 654Reputation: 654Reputation: 654
Sorry I haven't gotten back sooner. We have a flood here in Fargo. Life has been hectic.

It is common to have the users' directories under either /home/ or /var/samba/ or /srv/samba/.

So if you have 50 users with directories under /home/, e.g. /home/user1, /home/user2, /home/user3, then a share of /home will allow you to access all of the user's directories. You need to make sure that you have permission to enter these directories. Either by suing to root, or using setfacl to allow someone like a backup operator read access to each directory. A users directory will normally have something like
user1.user1 owner/group ownership and rwxrw----- permissions.

Since this is for backups, you could have an nfs share for /home. The other users don't need to know about this share.

Another option is to have the server do the backups.

Or you could ssh into the server and do the backups.

The backup method I find most convenient is to use a graphical tool to configure the jobs, but export the full & incremental backup jobs to a shell script. This gives you the convenience of a GUI tool allowing you to browse the filesystem to determine what needs to be backed up, which patterns shouldn't be compressed, which patterns shouldn't be backed up, which filesystems shouldn't be backed up (e.g. /tmp, /proc, /sys).

If you have several servers to backup, it is common to have a service running on each machine. E.G. Amanda.

Whatever you use, check what the guts of the program uses. Many may be nice front ends that produce tar or tar compatible archive files. Keep in mind that there are a number of tar formats that exist. Some may be able to backup more permissions & attributes than others. GNU tar can backup the ownership, permissions, and attributes of files, but I don't think it retains file acls. Star might. There is also dar, whick is intended to be used with CD or DVDs rather than tape.
 
  


Reply


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


Similar Threads
Thread Thread Starter Forum Replies Last Post
mount windows share export to samba share -> improve network performance tuning newuser77 Linux - Server 1 07-23-2008 11:28 AM
show the samba share but can't mount the share badall Linux - Server 3 05-30-2007 04:24 AM
searching samba share breaks connection to share Elomis Linux - Server 1 05-11-2007 12:28 AM
Linux Backup to Samba share on Windows NTFS DBThomson Linux - General 1 09-23-2005 03:01 AM
Simple Samba Setup, Share & Not Share timmywo Linux - Software 4 07-30-2004 07:27 AM


All times are GMT -5. The time now is 07:20 AM.

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