Senin, 01 November 2010

Setting SAMBA SERVER on Opensolaris/SUN machine

How to Configure Samba From the Command Line

1. Open a Terminal and assume the root role.
2. Copy the example file to the smb.conf file and open it with an editor.

# cd /etc/sfw # cp smb.conf-example smb.conf # vi smb.conf 

3. To make the setting active, remove any settings that begin with ";", as these are disabled. The template includes full comments for each setting.
4. Modify are the following settings:

  • [global]
    • workgroup = Change to your WORKGROUP.
  • [homes]
    • path = Add your path to your home directories ( /export/home/%u ).
    • browsable = Change to yes to allow the home share to be seen by the browser service.

5. Use the smbpasswd command to add your username.

# smbpasswd -a  New SMB password: Re-Type New SMB Password: Added user  

You are ready to start Samba.

How To Start Samba

1. Enable the samba and wins services.

# svcadm enable samba # svcadm enable wins 

2. Check that the daemons are online:
For example:

# svcs -a| grep wins online         16:06:20 svc:/network/wins:default # svcs -a | grep samba online         16:06:20 svc:/network/samba:default 

You should now be able to access your home directory and your printers from your Windows client.

If you've set browsable = yes in your smb.conf file, you should see the shares in Network Neighborhood.

Alternatively, you could map your home directory to always mount at login.


note: wiki SUN

yudhax


0 coment-ar: