Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com
Answertopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 

Using Samba
Prev Home Next

9.2.4.5 Testing daemons with testparm

Once you know there's a daemon, you should always run testparm, in hopes of getting:



server% testparm 

Load smb config files from /opt/samba/lib/smb.conf
Processing section "[homes]" 
Processing section "[printers]" ... 
Processing section "[tmp]" 
Loaded services file OK. ... 

The testparm program normally reports processing a series of sections, and responds with "Loaded services file OK" if it succeeds. If not, it will report one or more of the following messages, which will also appear in the logs as noted:

"Allow/Deny connection from account (n) to service"

A testparm-only message produced if you have valid/invalid user options set in your smb.conf. You will want to make sure that you are on the valid user list, and that root, bin, etc., are on the invalid user list. If you don't, you will not be able to connect, or folks who shouldn't will be able to.

"Warning: You have some share names that are longer than eight chars"

For anyone using Windows for Workgroups and older clients. They will fail to connect to shares with long names, producing an overflow message that sounds confusingly like a memory overflow.

"Warning: [name] service MUST be printable!"

A printer share lacks a printable = yes option.

"No path in service name using [name]"

A file share doesn't know which directory to provide to the user, or a print share doesn't know which directory to use for spooling. If no path is specified, the service will try to run with a path of /tmp, which may not be what you want.

"Note: Servicename is flagged unavailable"

Just a reminder that you have used the available = no option in a share.

"Can't find include file [name]"

A configuration file referred to by an include option did not exist. If you were including the file unconditionally, this is an error and probably a serious one: the share will not have the configuration you intended. If you were including it based one of the % variables, such as %a (architecture), you will need to decide if, for example, a missing Windows for Workgroups configuration file is a problem. It often isn't.

"Can't copy service name, unable to copy to itself"

You tried to copy a smb.conf section into itself.

"Unable to copy service - source not found: [name]"

Indicates a missing or misspelled section in a copy = option.

"Ignoring unknown parameter name"

Typically indicates an obsolete, misspelled or unsupported option.

"Global parameter name found in service section"

Indicates a global-only parameter has been used in an individual share. Samba will ignore the parameter.

After the testparm test, repeat it with (exactly) three parameters: the name of your smb.conf file, the name of your client, and its IP address:


testparm 

samba_directory/lib/smb.conf client 192.168.236.10

This will run one more test that checks the host name and address against host allow and host deny options and may produce the "Allow/Deny connection from account account_name" to service message for the client machine. This message indicates you have valid/invalid host options in your smb.conf, and they prohibit access from the client machine. Entering testparm /usr/local/lib/experimental.conf is also an effective way to test an experimental smb.conf file before putting it into production.

Using Samba
Prev Home Next

 
 
  Published under the terms of the Creative Commons License Design by Interspire