<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Daz's bits and bobs &#187; samba</title>
	<atom:link href="http://sigtar.com/tag/samba/feed/" rel="self" type="application/rss+xml" />
	<link>http://sigtar.com</link>
	<description>…bytes bits</description>
	<lastBuildDate>Mon, 26 Jul 2010 07:25:57 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Opensolaris &#8211; Samba and Network browsing</title>
		<link>http://sigtar.com/2009/09/06/opensolaris-samba-and-network-browsing/</link>
		<comments>http://sigtar.com/2009/09/06/opensolaris-samba-and-network-browsing/#comments</comments>
		<pubDate>Sun, 06 Sep 2009 07:21:32 +0000</pubDate>
		<dc:creator>Daz</dc:creator>
				<category><![CDATA[Networking]]></category>
		<category><![CDATA[OpenSolaris]]></category>
		<category><![CDATA[browsable]]></category>
		<category><![CDATA[master broswer]]></category>
		<category><![CDATA[netbios]]></category>
		<category><![CDATA[network]]></category>
		<category><![CDATA[nmbd]]></category>
		<category><![CDATA[samba]]></category>
		<category><![CDATA[workgroup]]></category>

		<guid isPermaLink="false">http://sigtar.com/?p=960</guid>
		<description><![CDATA[If you&#8217;ve setup samba (rather than the builtin cifs/smb) chances are that you can only browse to your samba shares directly on IP only.
If you want your box &#8220;network browseable&#8221; you&#8217;ll need to load nmbd.
You can find a really good write up on modifiying the SMF for samba to autostart the required service here : [...]


Related posts:<ol><li><a href='http://sigtar.com/2009/08/08/opensolaris-samba-server/' rel='bookmark' title='Permanent Link: OpenSolaris &#8211; Samba server'>OpenSolaris &#8211; Samba server</a> <small>Time to share your newly created ZFS volume via samba...</small></li>
<li><a href='http://sigtar.com/2009/08/03/opensolaris-network-teaming/' rel='bookmark' title='Permanent Link: opensolaris &#8211; network teaming'>opensolaris &#8211; network teaming</a> <small>Otherwise known as trunking or link aggregation. I believe it...</small></li>
<li><a href='http://sigtar.com/2009/11/13/iscsi-in-opensolaris/' rel='bookmark' title='Permanent Link: OpenSolaris &#8211; iSCSI'>OpenSolaris &#8211; iSCSI</a> <small>Want iSCSI in opensolaris? Grab SUNWiscsitgt via package manager. enable...</small></li>
</ol>

Related posts brought to you by <a href='http://mitcho.com/code/yarpp/'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<p>If you&#8217;ve setup samba (rather than the builtin cifs/smb) chances are that you can only browse to your samba shares directly on IP only.</p>
<p>If you want your box &#8220;network browseable&#8221; you&#8217;ll need to load nmbd.</p>
<p>You can find a really good write up on modifiying the SMF for samba to autostart the required service here : <a href="http://wikis.sun.com/display/BigAdmin/Enabling+Browsing+with+Samba+in+Solaris+10+Update+4">http://wikis.sun.com/display/BigAdmin/Enabling+Browsing+with+Samba+in+Solaris+10+Update+4</a></p>
<p>import this file <a href="http://sigtar.com/wp-content/uploads/2009/09/samba.xml">samba.xml</a></p>
<p>run these commands;</p>
<pre style="margin-top: 10px; margin-right: 0px; margin-bottom: 10px; margin-left: 0px; text-align: left; overflow-x: visible; overflow-y: visible; font-family: 'Courier New', Courier, monospace; line-height: 1.3; padding: 0px;"># svcadm disable samba
# svccfg import samba.xml
# svccfg delete svc:/network/samba:default
# svcadm refresh samba:smbd
# svcadm refresh samba:nmbd
# svcadm enable samba:smbd
# svcadm enable samba:nmbd</pre>


<p>Related posts:<ol><li><a href='http://sigtar.com/2009/08/08/opensolaris-samba-server/' rel='bookmark' title='Permanent Link: OpenSolaris &#8211; Samba server'>OpenSolaris &#8211; Samba server</a> <small>Time to share your newly created ZFS volume via samba...</small></li>
<li><a href='http://sigtar.com/2009/08/03/opensolaris-network-teaming/' rel='bookmark' title='Permanent Link: opensolaris &#8211; network teaming'>opensolaris &#8211; network teaming</a> <small>Otherwise known as trunking or link aggregation. I believe it...</small></li>
<li><a href='http://sigtar.com/2009/11/13/iscsi-in-opensolaris/' rel='bookmark' title='Permanent Link: OpenSolaris &#8211; iSCSI'>OpenSolaris &#8211; iSCSI</a> <small>Want iSCSI in opensolaris? Grab SUNWiscsitgt via package manager. enable...</small></li>
</ol></p>
<p>Related posts brought to you by <a href='http://mitcho.com/code/yarpp/'>Yet Another Related Posts Plugin</a>.</p>]]></content:encoded>
			<wfw:commentRss>http://sigtar.com/2009/09/06/opensolaris-samba-and-network-browsing/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>OpenSolaris &#8211; Samba server</title>
		<link>http://sigtar.com/2009/08/08/opensolaris-samba-server/</link>
		<comments>http://sigtar.com/2009/08/08/opensolaris-samba-server/#comments</comments>
		<pubDate>Fri, 07 Aug 2009 23:00:24 +0000</pubDate>
		<dc:creator>Daz</dc:creator>
				<category><![CDATA[OpenSolaris]]></category>
		<category><![CDATA[opensolaris]]></category>
		<category><![CDATA[samba]]></category>
		<category><![CDATA[smb]]></category>
		<category><![CDATA[swat]]></category>
		<category><![CDATA[zfs]]></category>

		<guid isPermaLink="false">http://dwtaylornz.wordpress.com/?p=66</guid>
		<description><![CDATA[Time to share your newly created ZFS volume via samba to your windows clients.  There is some CIFS / SMB support built into the kernel now, but i&#8217;ve grown used to the SMB server&#8230;
Fire up add software &#8211; click filesystems &#8211; enable filter for &#8220;smb&#8221;, there are three packages generally. I get all three, but [...]


Related posts:<ol><li><a href='http://sigtar.com/2009/09/06/opensolaris-samba-and-network-browsing/' rel='bookmark' title='Permanent Link: Opensolaris &#8211; Samba and Network browsing'>Opensolaris &#8211; Samba and Network browsing</a> <small>If you&#8217;ve setup samba (rather than the builtin cifs/smb) chances...</small></li>
<li><a href='http://sigtar.com/2009/11/13/iscsi-in-opensolaris/' rel='bookmark' title='Permanent Link: OpenSolaris &#8211; iSCSI'>OpenSolaris &#8211; iSCSI</a> <small>Want iSCSI in opensolaris? Grab SUNWiscsitgt via package manager. enable...</small></li>
<li><a href='http://sigtar.com/2010/04/11/opensolaris-v134-cifs-has-gone-walkies/' rel='bookmark' title='Permanent Link: opensolaris v134 &#8211; CIFS has gone walkies'>opensolaris v134 &#8211; CIFS has gone walkies</a> <small>Errr, I cant find the CIFS service in the 134...</small></li>
</ol>

Related posts brought to you by <a href='http://mitcho.com/code/yarpp/'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<p>Time to share your newly created ZFS volume via samba to your windows clients.  There is some CIFS / SMB support built into the kernel now, but i&#8217;ve grown used to the SMB server&#8230;</p>
<p>Fire up add software &#8211; click filesystems &#8211; enable filter for &#8220;smb&#8221;, there are three packages generally. I get all three, but you only need the kernel update and the server package. The other is the SMB client.</p>
<p>Once installed make sure you enable the server in <strong>services</strong>gui.</p>
<p>Ensure the filesystem does not have any permission issues. I usually run <strong>chmod -R 777 /<em>share</em></strong><em> </em>just to ensure everyone can access the files without issue.</p>
<p>Add some users into smb password file (U need to create the users and sync the passwords). I usually create a guest user profile</p>
<p><strong>useradd guest</strong></p>
<p><strong>smbpasswd -a guest </strong>- it should prompt for password twice (this is the password you use from windows). Press enter twice to leave the password blank.</p>
<p>The configuration can be done via <strong>/etc/sfw/smb.conf</strong> or via the shared folders admin gui.</p>
<p>I prefer doing the admin via the <strong>/etc/sfw/smb.conf</strong>file as it tends to let you have more control than the basic options available to you via the GUI. The contents of the file are as follows;  (note: i have included alot of the setting as an example which may contridict other settings)</p>
<p><strong>[global]</strong> &#8211; global settings, the following are obvious</p>
<p><strong>workgroup = workgroup</strong></p>
<p><strong>server string = opensolaris</strong></p>
<p><strong>wins support = yes </strong>- lets your server act as a WINS box</p>
<p><strong><br />
</strong></p>
<p><strong>[share]</strong> &#8211; share name</p>
<p><strong>path = /raidz1/share</strong> &#8211; share path</p>
<p><strong>available = yes </strong>- enabled?</p>
<p><strong>browseable = yes </strong></p>
<p><strong>public = yes</strong></p>
<p><strong>valid users = user1, user2 </strong>- only these users can access the share</p>
<p><strong>writable = yes </strong>- equivalent to read / write in windows share properties</p>
<p><strong>read only = yes</strong> &#8211; sets the default permissions to read only</p>
<p><strong>write list = user1, user2 -</strong> these users can write to the share. Overrides above &#8220;read only&#8221; setting.</p>
<p>There are some good examples within <strong>/etc/sfw/smb.conf-example</strong>. Look there for some tips.</p>
<p>You also have an option of managing samba via the web &#8211; SWAT (samba web admin t). To get this up an running enable the swat service <em>svc:/network/swat:default </em>then browse to http://server:901</p>
<p>Optimizing SMB</p>
<p>I&#8217;ve found that adding this to <strong>/etc/sfw/smb.conf </strong>helps throughput in some cases. Try for yourself;  (it tends to put a higher load on cpu)</p>
<p><strong>[global]</strong></p>
<p><strong>aio read size = 1<br />
aio write size = 1</strong></p>
<p>Further to this entry i have discovered that the built in CIFS / SMB service is much more efficient since it is included as part of the kernel. See my other posts on setting up cifs</p>
<p><strong><em>Updated : 9/08/2009</em></strong></p>
<p>I&#8217;ve swapped back to samba due to the issues i&#8217;ve had with cifs in the later releases. Remember if you wish to swap back to samba yo uneed to remove the sharesmb properties from each of your zfs shares &#8211; else on reboot zfs will re-enable the server/smb service.</p>
<p>There are some additional settings to ensure that your file server is the master browser for your workgroup. Put these under your [global]</p>
<p><strong>[global]<br />
domain master = Yes<br />
local master = Yes<br />
preferred master = Yes<br />
os level = 35</strong></p>
<p>Apparently on windows the <em>os level</em> reaches only 32 &#8211; so setting this to 35 ensures that your file server remains the master browser when an election is performed.</p>


<p>Related posts:<ol><li><a href='http://sigtar.com/2009/09/06/opensolaris-samba-and-network-browsing/' rel='bookmark' title='Permanent Link: Opensolaris &#8211; Samba and Network browsing'>Opensolaris &#8211; Samba and Network browsing</a> <small>If you&#8217;ve setup samba (rather than the builtin cifs/smb) chances...</small></li>
<li><a href='http://sigtar.com/2009/11/13/iscsi-in-opensolaris/' rel='bookmark' title='Permanent Link: OpenSolaris &#8211; iSCSI'>OpenSolaris &#8211; iSCSI</a> <small>Want iSCSI in opensolaris? Grab SUNWiscsitgt via package manager. enable...</small></li>
<li><a href='http://sigtar.com/2010/04/11/opensolaris-v134-cifs-has-gone-walkies/' rel='bookmark' title='Permanent Link: opensolaris v134 &#8211; CIFS has gone walkies'>opensolaris v134 &#8211; CIFS has gone walkies</a> <small>Errr, I cant find the CIFS service in the 134...</small></li>
</ol></p>
<p>Related posts brought to you by <a href='http://mitcho.com/code/yarpp/'>Yet Another Related Posts Plugin</a>.</p>]]></content:encoded>
			<wfw:commentRss>http://sigtar.com/2009/08/08/opensolaris-samba-server/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>OpenSolaris &#8211; Migrating from samba to cifs</title>
		<link>http://sigtar.com/2009/02/13/opensolaris-migrating-from-samba-to-cifs/</link>
		<comments>http://sigtar.com/2009/02/13/opensolaris-migrating-from-samba-to-cifs/#comments</comments>
		<pubDate>Thu, 12 Feb 2009 19:07:37 +0000</pubDate>
		<dc:creator>Daz</dc:creator>
				<category><![CDATA[Networking]]></category>
		<category><![CDATA[OpenSolaris]]></category>
		<category><![CDATA[cifs]]></category>
		<category><![CDATA[opensolaris]]></category>
		<category><![CDATA[samba]]></category>
		<category><![CDATA[smb]]></category>

		<guid isPermaLink="false">http://sigtar.com/?p=292</guid>
		<description><![CDATA[OpenSolaris 2008.11 has a cifs/smb server built into the kernel. From what i have been reading (and discovering) this is a much more efficient and faster way to get your files out into the network.
Previously i have run a dedicated samba service to share my files as I&#8217;ve come from various linux distros which require [...]


Related posts:<ol><li><a href='http://sigtar.com/2009/08/08/opensolaris-samba-server/' rel='bookmark' title='Permanent Link: OpenSolaris &#8211; Samba server'>OpenSolaris &#8211; Samba server</a> <small>Time to share your newly created ZFS volume via samba...</small></li>
<li><a href='http://sigtar.com/2009/09/06/opensolaris-samba-and-network-browsing/' rel='bookmark' title='Permanent Link: Opensolaris &#8211; Samba and Network browsing'>Opensolaris &#8211; Samba and Network browsing</a> <small>If you&#8217;ve setup samba (rather than the builtin cifs/smb) chances...</small></li>
</ol>

Related posts brought to you by <a href='http://mitcho.com/code/yarpp/'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<p>OpenSolaris 2008.11 has a cifs/smb server built into the kernel. From what i have been reading (and discovering) this is a much more efficient and faster way to get your files out into the network.</p>
<div>Previously i have run a dedicated samba service to share my files as I&#8217;ve come from various linux distros which require it. Seems i should be doing things differently on OpenSolaris.</div>
<p>The dedicated samba service is called;</p>
<p><strong>svc:/network/samba:default</strong></p>
<p>The new kernel embedded solaris smb/cifs service is called;</p>
<p><strong>svc:/network/smb/server:default</strong></p>
<p>If you do not have it running or installed you&#8217;ll need to add the following packages (use package manager); </p>
<p><strong>SUNWsmbs </strong></p>
<p><strong>SUNWsmbskr</strong></p>
<p><strong>Update : both these packages are called SUNWsmbfs in newer builds</strong></p>
<p>Enable the service via &#8220;services&#8221; gui else use the <strong>svcadm </strong>command; </p>
<p><strong>svcadm enable svc:/network/smb/server:default</strong></p>
<p>This is a great page on how to do a basic cifs setup <a href="http://blogs.sun.com/timthomas/entry/solaris_cifs_in_workgroup_mode" target="_blank">http://blogs.sun.com/timthomas/entry/solaris_cifs_in_workgroup_mode</a></p>
<p>I just need to find a bit more detail on how to configure access to the shares (update: see below). In another post i made previously using samba it was easy enough to restrict guests to read only while giving some users rw access&#8230; I&#8217;m also interested in whether its possible to backup or manually configure the cifs server via any config file? <em>Still looking into this one.</em></p>
<p>First step is to disable the samba service and enable the solaris smb/cifs service;</p>
<p><strong>svcadm disable network/samba</strong></p>
<p><strong>svcadm enable -r smb/server </strong>- the &#8220;r&#8221; switch also enables all services that smb requires.</p>
<p>The next step is to add the following line to your <strong>/etc/pam.conf</strong> file. This is so future changes to passwords  also update the smb password file;</p>
<p><strong>other   password required       pam_smb_passwd.so.1     nowarn</strong></p>
<p>now set the name of the workgroup&#8230;</p>
<p><strong>smbadm join -w workgroup</strong></p>
<p>now setup your users (you have to reset your current passwords to update the password file above). I usually create and use a &#8220;Guest&#8221; account to keep some windows boxes happy. I set the guest account password to blank&#8230; </p>
<p><strong>useradd guest </strong></p>
<p><strong>passwd guest</strong> &#8211; then enter twice to enter a blank password</p>
<p>Next its time to setup the actual shares. If you have a zfs pool setup (you most likey do if you are running opensolaris) then you can share your data via the zfs command like so&#8230;.   (i have a &#8220;backups&#8221; zfs file system within a &#8220;unprotected&#8221; zpool)</p>
<p><strong>zfs set sharesmb=on unprotected/backups</strong></p>
<p>Unfortunately this creates a share called &#8220;unprotected_backups&#8221; which can be seen via the <strong>sharemgr show -vp </strong>command. To rename the share to something more appropriate do the following&#8230;</p>
<p><strong>zfs set sharesmb=name=backups unprotected/backups</strong></p>
<p>All going well the share should now be called &#8220;backups&#8221;, if you have both the old and new name listed restart the smb server : <strong>svcadm restart smb/server</strong></p>
<p>From your windows machine you should be able to browse to your share via <strong>\\servername\backups</strong>, if you get a prompt then type &#8220;guest&#8221; and press enter. Here is an example of a quick and easy way to mount drives via an XP commandline&#8230;</p>
<p><strong>net use * \\serverip\backups /user:guest</strong></p>
<p>Update: i have figured out the ACLs for cifs &#8212; <a href="http://sigtar.com/2009/02/14/opensolaris-cifssmb-server-configuring-acls-on-shares/" target="_blank">See this Post</a></p>


<p>Related posts:<ol><li><a href='http://sigtar.com/2009/08/08/opensolaris-samba-server/' rel='bookmark' title='Permanent Link: OpenSolaris &#8211; Samba server'>OpenSolaris &#8211; Samba server</a> <small>Time to share your newly created ZFS volume via samba...</small></li>
<li><a href='http://sigtar.com/2009/09/06/opensolaris-samba-and-network-browsing/' rel='bookmark' title='Permanent Link: Opensolaris &#8211; Samba and Network browsing'>Opensolaris &#8211; Samba and Network browsing</a> <small>If you&#8217;ve setup samba (rather than the builtin cifs/smb) chances...</small></li>
</ol></p>
<p>Related posts brought to you by <a href='http://mitcho.com/code/yarpp/'>Yet Another Related Posts Plugin</a>.</p>]]></content:encoded>
			<wfw:commentRss>http://sigtar.com/2009/02/13/opensolaris-migrating-from-samba-to-cifs/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Linux &#8211; mapping to a windows share (SMB)</title>
		<link>http://sigtar.com/2009/02/03/linux-mapping-to-a-windows-share-smb/</link>
		<comments>http://sigtar.com/2009/02/03/linux-mapping-to-a-windows-share-smb/#comments</comments>
		<pubDate>Tue, 03 Feb 2009 01:10:10 +0000</pubDate>
		<dc:creator>Daz</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Networking]]></category>
		<category><![CDATA[samba]]></category>

		<guid isPermaLink="false">http://sigtar.com/?p=173</guid>
		<description><![CDATA[As per below. First you will need to install samba client.
In Fedora / Centos &#8230;
yum -y samba-client
then use the mount command to mount the share to a directory&#8230; 
mount -t cifs -n //192.168.9.70/software /mnt/sharename -o username=guest,password=
It will be similar in other distros. Remember to create the /mnt/sharename directory before trying to mount any share to the [...]


Related posts:<ol><li><a href='http://sigtar.com/2009/08/08/opensolaris-samba-server/' rel='bookmark' title='Permanent Link: OpenSolaris &#8211; Samba server'>OpenSolaris &#8211; Samba server</a> <small>Time to share your newly created ZFS volume via samba...</small></li>
</ol>

Related posts brought to you by <a href='http://mitcho.com/code/yarpp/'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<p>As per below. First you will need to install samba client.</p>
<p>In Fedora / Centos &#8230;</p>
<p style="TEXT-ALIGN: left"><strong>yum -y samba-client</strong></p>
<p style="TEXT-ALIGN: left">then use the <strong>mount </strong>command to mount the share to a directory&#8230; </p>
<p style="TEXT-ALIGN: left"><strong>mount -t cifs -n //192.168.9.70/software /mnt/sharename -o username=guest,password=</strong></p>
<p>It will be similar in other distros. Remember to create the <strong>/mnt/sharename</strong> directory before trying to mount any share to the directory. Directories are created like so;</p>
<p style="TEXT-ALIGN: left"><strong>mkdir /mnt/sharename</strong></p>


<p>Related posts:<ol><li><a href='http://sigtar.com/2009/08/08/opensolaris-samba-server/' rel='bookmark' title='Permanent Link: OpenSolaris &#8211; Samba server'>OpenSolaris &#8211; Samba server</a> <small>Time to share your newly created ZFS volume via samba...</small></li>
</ol></p>
<p>Related posts brought to you by <a href='http://mitcho.com/code/yarpp/'>Yet Another Related Posts Plugin</a>.</p>]]></content:encoded>
			<wfw:commentRss>http://sigtar.com/2009/02/03/linux-mapping-to-a-windows-share-smb/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
