How do I restart the Samba service?

1,316

Solution 1

sudo /etc/init.d/samba restart should be all you need to do.

Solution 2

It looks like ubuntu has changed the name of the service you need to restart to smbd. For me (on ubuntu server 12.04) the correct command was

sudo service smbd restart

Editor's notes: I can't comment, or this would be a comment to the above answer. I realize this is an old question, but I landed here looking for the very same thing, and the comment was enough of a hint to me to figure out the rest, so I thought I'd record the update.

Solution 3

In a production environment it's not advisable to restart a service for just configuration changes. I suggest you go with:

sudo service smbd reload

Whats the advantage of reload?

Reload will just update the configuration changes, with out restarting the service.

Share:
1,316

Related videos on Youtube

user784625
Author by

user784625

Updated on September 17, 2022

Comments

  • user784625
    user784625 over 1 year

    I have UIScrollView that contains several UIView when I try to setAlpha: for one of the UIView, I get 1.5 second delay till the UIView alpha is set.

    Here is the code below setContentOffset does run before the setAlpha: although the setAlpha: is written before in code

    -(void)setAlphaForIndex:(int)Index{
    
        for (UIView *v in imgScroll.subviews){
    
            if (v.tag == Index) {
                [v setAlpha:0.6];
                if (![self checkIfImageInScrollRange:Index]){
                    if (v.tag < 5)
                        [imgScroll setContentOffset:CGPointMake(0, 0) animated:YES];
                    else
                        [imgScroll setContentOffset:CGPointMake((Index - 5) * (CELLWIDTH) + (Index - 5 - 1) * 3, 0) animated:YES];
                }
            } else {
                [v setAlpha:1.0];
            }
        }
    }
    
  • streetlight
    streetlight over 14 years
    sudo service samba restart sudo service samba restart. Looks like windows :))