<?xml version="1.0" encoding="utf-8"?>
<?xml-stylesheet type="text/css" href="http://brandonhutchinson.com/mediawiki/skins/common/feed.css?97"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
	<channel>
		<title>&quot;IO::Socket::INET: Bad protocol 'tcp'&quot; - Revision history</title>
		<link>http://brandonhutchinson.com/mediawiki/index.php5?title=%22IO::Socket::INET:_Bad_protocol_%27tcp%27%22&amp;action=history</link>
		<description>Revision history for this page on the wiki</description>
		<language>en</language>
		<generator>MediaWiki 1.11.0rc1</generator>
		<lastBuildDate>Sat, 18 May 2013 06:42:54 GMT</lastBuildDate>
		<item>
			<title>Hutch: New page:  IO::Socket::INET: Bad protocol 'tcp' at /tmp/script.pl line 7, &lt;DATA&gt; line 225.  You may receive this error if your system cannot convert the '''tcp''' protocol to its number using getpro...</title>
			<link>http://brandonhutchinson.com/mediawiki/index.php5?title=%22IO::Socket::INET:_Bad_protocol_%27tcp%27%22&amp;diff=1314&amp;oldid=prev</link>
			<description>&lt;p&gt;New page:  IO::Socket::INET: Bad protocol 'tcp' at /tmp/script.pl line 7, &amp;lt;DATA&amp;gt; line 225.  You may receive this error if your system cannot convert the '''tcp''' protocol to its number using getpro...&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt; IO::Socket::INET: Bad protocol 'tcp' at /tmp/script.pl line 7, &amp;lt;DATA&amp;gt; line 225.&lt;br /&gt;
&lt;br /&gt;
You may receive this error if your system cannot convert the '''tcp''' protocol to its number using getprotobyname().&lt;br /&gt;
&lt;br /&gt;
 $ '''getent protocols tcp'''&lt;br /&gt;
 $&lt;br /&gt;
&lt;br /&gt;
In my case, this happened because after configuring a Solaris LDAP client using '''ldapclient'''. This command copies '''/etc/nsswitch.ldap''' over '''/etc/nsswitch.conf'''. The problematic line:&lt;br /&gt;
 $ '''grep protocols /etc/nsswitch.conf'''&lt;br /&gt;
 protocols:  ldap [NOTFOUND=return] files&lt;br /&gt;
&lt;br /&gt;
I changed the line to:&lt;br /&gt;
 protocols:  files ldap&lt;br /&gt;
&lt;br /&gt;
and had no more problems.&lt;br /&gt;
&lt;br /&gt;
 $ '''getent protocols tcp'''&lt;br /&gt;
 tcp                  6 TCP&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
&lt;br /&gt;
* [http://osdir.com/ml/lang.perl.modules.ldap/2005-10/msg00014.html Re: IO::Socket::SSL: Bad protocol 'tcp']&lt;/div&gt;</description>
			<pubDate>Mon, 18 Aug 2008 23:22:10 GMT</pubDate>			<dc:creator>Hutch</dc:creator>			<comments>http://brandonhutchinson.com/wiki/Talk:%22IO::Socket::INET:_Bad_protocol_%27tcp%27%22</comments>		</item>
	</channel>
</rss>