Home Man
Search
Today's Posts
Register

Linux & Unix Commands - Search Man Pages

OpenSolaris 2009.06 - man page for smbutil (opensolaris section 1)

smbutil(1)				  User Commands 			       smbutil(1)

NAME
       smbutil - Solaris CIFS client utility

SYNOPSIS
       /usr/bin/smbutil crypt

       /usr/bin/smbutil login [-c] [[domain/]user]

       /usr/bin/smbutil login [-c] [user[@domain]]

       /usr/bin/smbutil logout [[domain/]user]

       /usr/bin/smbutil logout [user[@domain]]

       /usr/bin/smbutil logout -a

       /usr/bin/smbutil logoutall

       /usr/bin/smbutil lookup name

       /usr/bin/smbutil status server

       /usr/bin/smbutil view [-A | -U user] //[domain;][user[:password]@]server

       /usr/bin/smbutil [-?dv]

DESCRIPTION
       The smbutil command controls the Solaris CIFS client and issues various commands.

   Subcommands
       The smbutil command supports the following subcommands:

       crypt

	   Creates  a  hash  of a password. This subcommand prompts for a password and writes the
	   hash to standard output. This hash value is suitable for use as a value for the  pass-
	   word property in the $HOME/.nsmbrc file.

	   The hashed password begins with two dollar signs ($$). If you assign this hashed pass-
	   word to the password property in your $HOME/.nsmbrc, be sure that you escape the  spe-
	   cial characters in the password.

	   If you plan to store hashed passwords in your $HOME/.nsmbrc file, ensure that the file
	   permissions are set so that only the owner can read or write the file (400 or 600), or
	   the passwords are ignored.

       login [-c] [ [[domain/]user] | [user[@domain] ]

	   Specifies  persistent  password information to be used for a CIFS server user account.
	   When you specify this information, mounts can be done without  a  password  prompt  in
	   non-Kerberos  configurations.  Kerberos  sites  should use Kerberos automatically, not
	   prompt for a password. If a default domain is  available  in  SMF  or  nsmbrc(4),  the
	   domain  can be omitted. If a user name is not specified, the Solaris user account name
	   is used.

	   Use the -c to check whether a persistent password is set for the specified user.

	   Passwords can also be stored for a specific server by using a server name in place  of
	   the domain name. This capability is useful with servers that are configured for "work-
	   group mode."

       logout [ [[domain/]user] | [user[@domain] ]

	   Erases the persistent passwords that are stored for the Solaris user account  name  of
	   the person running the command.

	   If  any  part  of user name, domain or user, is not specified, the password is deleted
	   for the user who specified by the user and domain properties  described  in	the  nsm-
	   brc(4) manual page.

	   If you stored your password for a specific server, specify the server name in place of
	   the domain name.

       logout -a

	   Erases all of the persistent passwords that are stored for the user who is running the
	   command.

       logoutall

	   Erases  all	the persistent passwords that are stored by all users running the smbutil
	   login command.

	   This command must be run as superuser.

       lookup name

	   Resolves the specified name to an IP address.

	   This subcommand is only supported if an NBNS/WINS name server is available.

       status server

	   Resolves the specified server to the NetBIOS domain and system name. server can be  an
	   IP address or a DNS name.

       view [-A | -U user]  //[domain;][user[:password]@]server

	   Lists the resources available to user on the specified server.

	   You	can  specify  the  -A option to view the resources as an anonymous user or the -U
	   user option to view the resources as the specified user. These  options  are  mutually
	   exclusive.

	   If  the  resource  includes a domain, you must escape the semicolon that appears after
	   the domain name to prevent it  from	being  interpreted  by	the  command  shell.  For
	   instance,  surround	the  entire  resource  name  with  single  quotes:  smbutil  view
	   '//SALES;george@RSERVER'.

OPTIONS
       The following global options are supported:

       -d	    Produces debugging output.

       -v	    Produces verbose output.

       -?	    Prints a short help message.

EXAMPLES
       Example 1 Creating a Password Hash for the $HOME/.nsmbrc File

       The following example shows how to use the smbutil crypt command to create a hash  of  the
       password you specify. Then, you can use the hash as the value for the $HOME/.nsmbrc file.

       Be  sure  to escape the two dollar-sign prefix of the hashed password if you store it as a
       value of the password property.

	 $ smbutil crypt
	 Password:
	 $$178465324253e0c07

       The following $HOME/.nsmbrc file fragment shows how the password hash value is set:

	 [RSERVER:george]
	 charsets=koi8-r:cp866
	 password='$$178465324253e0c07'

       Example 2 Storing a Password for a CIFS Server

       The following example shows how to use the smbutil login command to store the root@example
       user's password.

	 $ smbutil login root@example
	 Password:

       Example 3 Erasing the Stored Password

       The following example shows how to use the smbutil logout command to remove the root@exam-
       ple user's password.

	 $ smbutil logout root@example

       Example 4 Viewing Available Shares

       The following example shows how to use the smbutil  view  command  to  see  the	available
       shares for user root on server example.

	 $ smbutil view //root@example
	 Password:
	 Share	      Type	 Comment
	 -------------------------------
	 netlogon     disk	 Network Logon Service
	 ipc$	      IPC	 IPC Service (Samba Server)
	 tmp	      disk	 Temporary file space
	 public       disk	 Public Stuff
	 root	      disk	 Home Directories

	 5 shares listed from 5 available

       Example 5 Viewing Available Shares as an Anonymous User

       The  following  example	shows how to use the smbutil view command to anonymously view the
       available shares on the example server.

	 $ smbutil view -A //example
	 Share	      Type	 Comment
	 -------------------------------
	 netlogon     disk	 Network Logon Service
	 ipc$	      IPC	 IPC Service (Samba Server)
	 tmp	      disk	 Temporary file space
	 public       disk	 Public Stuff
	 ethereal     disk	 /export/ethereal
	 myshare      disk	 Jan's stuff

	 6 shares listed from 6 available

       Example 6 Obtaining the IP Address From a Server Name

       The following example shows how to use the smbutil lookup command to obtain the IP address
       of the example server.

	 $ smbutil lookup example
	 Got response from 192.168.168.210
	 IP address of example: 192.168.168.210

       Example 7 Obtaining the NetBIOS Domain and System Name Using the Server Name

       The  following  example	shows how to use the smbutil status command to obtain the NetBIOS
       domain and system name of the example server. The server name, example,	is  specified  on
       the command line.

	 $ smbutil status example
	 Domain: WORKGROUP
	 Server: EXAMPLE

       Example 8 Obtaining the NetBIOS Domain and System Name Using the IP Address

       The  following  example	shows how to use the smbutil status command to obtain the NetBIOS
       domain and system name of the example server. The IP address, 192.168.168.210,  is  speci-
       fied on the command line.

	 $ smbutil status 192.168.168.210
	 Domain: WORKGROUP
	 Server: EXAMPLE

FILES
       $HOME/.nsmbrc

	   User-settable mount point configuration file to store the description for each connec-
	   tion.

ATTRIBUTES
       See attributes(5) for descriptions of the following attributes:

       +-----------------------------+-----------------------------+
       |      ATTRIBUTE TYPE	     |	    ATTRIBUTE VALUE	   |
       +-----------------------------+-----------------------------+
       |Availability		     |SUNWsmbfscu		   |
       +-----------------------------+-----------------------------+
       |Interface Stability	     |See below.		   |
       +-----------------------------+-----------------------------+

       The output is Uncommitted. The rest of the interface is Committed.

SEE ALSO
       mount_smbfs(1M), nsmbrc(4), attributes(5), smbfs(7FS)

AUTHORS
       This manual page contains  material  originally	authored  by  Boris  Popov,  bp@butya.kz,
       bp@FreeBSD.org.

NOTES
       The  Solaris  CIFS client always attempts to use gethostbyname() to resolve host names. If
       the host name cannot be resolved, the CIFS client uses NetBIOS name resolution (NBNS).  By
       default, the Solaris CIFS client permits the use of NBNS to enable Solaris CIFS clients in
       Windows environments to work without additional configuration.

       Since NBNS has been exploited in the past, you might want to disable it. To disable  NBNS,
       set  the  nbns-enabled  service	management  facility property to false. By default, nbns-
       enabled is set to true.

SunOS 5.11				   18 Aug 2008				       smbutil(1)


All times are GMT -4. The time now is 01:13 AM.

Unix & Linux Forums Content Copyrightę1993-2018. All Rights Reserved.
UNIX.COM Login
Username:
Password:  
Show Password