When you cycle the samba server, all connection to the shares will be broken but the clients reconnect when they see this happen. At least for windows clients, this should be transparent unless someone tries to access your server in the exact time you are restarting it.
Before you restart your server, you can issue a SMBSTATUS command to see if there are any open files or not. You will see client connections to shares but you want to watch out for open files. If you recycle the server while files are open, those application with open files will get upset. You can minimize your samba outage to seconds by using the RSYNC command I pointed out in an earlier post just before you shutdown your samba server and immediately after you shutdown the server and before you start it again in its new home. Depending on the size of your file system, this could be just seconds. I am not sure how much shorter you can make this outage. Aria > -----Original Message----- > From: Linux on 390 Port [mailto:[email protected]] On Behalf Of > Tom Duerbusch > Sent: Wednesday, September 09, 2009 4:39 PM > To: [email protected] > Subject: Re: Moving a Samba directory > > Like I said, I knew the answer to this one (i.e. shutdown Samba), but I > hoping for a quick and dirty way, of doing the conversion with Samba > still up. > > Well, once this is done, I can then add disks to the LVM on the fly. > Just hate to have to do the scheduling of downtime (users and servers) > when I know no one is going to be active anyway, just their shares are > in use. > > Right? When I cycle the server, the users have to reaccess their > shares? It's the servers that are accessing the Samba shares, then > also have to be cycled....and those users have to be notified... > > Thanks > > Tom Duerbusch > THD Consulting > > >>> Justin Payne <[email protected]> 9/9/2009 2:41 PM >>> > If you do not stop the samba service you run a risk of files being > accessed during the move, and this could lead to corruption of the new > files. As recommended before, you should be able to copy the bulk of > the > data without shutting down the service. With the bulk of the data > mirrored on the new LVM, the second rsync will be quite quick at > syncing > only the changes so downtime will be minimal. > > It would be best to plan a brief outage of the samba service to > complete > the task you have outlined. > > Justin Payne > > On 09/09/2009 12:53 PM, Tom Duerbusch wrote: > > I think I know the answer to this one, but then, I don't know how > much I don't know<G>. > > > > I have a Samba server that runs 24X7. It is rarely used at night, > but still has Windows shares active. > > The /home directory is located off the / directory (dasda1). It > needs more space. > > I've created a LVM with a directory name of /home2. > > I plan on copying the /home directory to /home2, rename /home to > /homeold, and rename /home2 to /home. > > Simple. > > > > What is Samba going to think about this? > > Do I need to cycle Samba, and have all the currently connected users, > reconnect? > > Or as long as Samba isn't trying to access a file during this period > of time, would it care? > > > > Part of this is trying to decide how much notification I have to give > the end users, and there are a couple "servers" that also have Samba > shares. I don't know how to reconnect them, other than cycling those > servers, which, then requires additional notification. > > > > On my test system, I moved the Samba /home directory to a LVM setup. > No problem. But I didn't have any currently accessed shares at that > time (poor test plan). > > > > Thanks for any input and direction. > > > > Tom Duerbusch > > THD Consulting > > > > --------------------------------------------------------------------- > - > > For LINUX-390 subscribe / signoff / archive access instructions, > > send email to [email protected] with the message: INFO LINUX-390 > or visit > > http://www.marist.edu/htbin/wlvindex?LINUX-390 > > > > ---------------------------------------------------------------------- > For LINUX-390 subscribe / signoff / archive access instructions, > send email to [email protected] with the message: INFO LINUX-390 > or visit > http://www.marist.edu/htbin/wlvindex?LINUX-390 > > ---------------------------------------------------------------------- > For LINUX-390 subscribe / signoff / archive access instructions, > send email to [email protected] with the message: INFO LINUX-390 > or visit > http://www.marist.edu/htbin/wlvindex?LINUX-390 ---------------------------------------------------------------------- For LINUX-390 subscribe / signoff / archive access instructions, send email to [email protected] with the message: INFO LINUX-390 or visit http://www.marist.edu/htbin/wlvindex?LINUX-390
