<?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>Tuts4Tech &#187; tutorial</title>
	<atom:link href="http://tuts4tech.net/tag/tutorial/feed/" rel="self" type="application/rss+xml" />
	<link>http://tuts4tech.net</link>
	<description>Tech Tutorials</description>
	<lastBuildDate>Sun, 18 Jul 2010 01:41:08 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>Nano write check before editing</title>
		<link>http://tuts4tech.net/2009/07/08/nano-write-check-before-editing/</link>
		<comments>http://tuts4tech.net/2009/07/08/nano-write-check-before-editing/#comments</comments>
		<pubDate>Wed, 08 Jul 2009 18:29:35 +0000</pubDate>
		<dc:creator>Duffy</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[check]]></category>
		<category><![CDATA[configurations]]></category>
		<category><![CDATA[nano]]></category>
		<category><![CDATA[premissions]]></category>
		<category><![CDATA[read]]></category>
		<category><![CDATA[sudo]]></category>
		<category><![CDATA[tutorial]]></category>
		<category><![CDATA[users]]></category>
		<category><![CDATA[wheel]]></category>
		<category><![CDATA[write]]></category>

		<guid isPermaLink="false">http://tuts4tech.net/?p=463</guid>
		<description><![CDATA[Have you ever been using nano to edit a long configuration file and when you've just finished you go to save and you get "Error writing /dir/somefile: Permission denied" as you've forgotten to use sudo or switch user if so this tutorial might just be your solution. What this does is it runs a script [...]]]></description>
			<content:encoded><![CDATA[<p>Have you ever been using nano to edit a long configuration file and when you've just finished you go to save and you get "Error writing /dir/somefile: Permission denied" as you've forgotten to use sudo or switch user if so this tutorial might just be your solution. What this does is it runs a script to check if you have write access on the file if you do it will continue and open nano as normal if you don't it will ask you do you want to continue so lets get started</p>
<ol>
<li>Save the following to /usr/bin/writecheck
<pre class="brush: bash;">#!/bin/bash
FILE=&quot;$1&quot;

[ $# -eq 0 ] &amp;&amp; exit 1

if [ -w &quot;$FILE&quot; ]
then
nano $FILE
else
   echo &quot;You Do Not Have Write Acess To $FILE&quot;
   echo -n &quot;Do You Want To Continue (y/n)?&quot;
   read reply
   [ $reply == &quot;y&quot; ] &amp;&amp; nano $FILE
fi</pre>
</li>
<li>Allow the script to be executed
<pre class="brush: bash;">chmod +x /usr/bin/writecheck</pre>
</li>
<li>Finally we need to add a alias for it
<pre class="brush: bash;">echo &quot;alias nano='writecheck'&quot; &gt;&gt; /etc/bash.bashrc</pre>
</li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://tuts4tech.net/2009/07/08/nano-write-check-before-editing/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Disabling IPV6 on Debian</title>
		<link>http://tuts4tech.net/2009/07/07/disabling-ipv6-on-debian/</link>
		<comments>http://tuts4tech.net/2009/07/07/disabling-ipv6-on-debian/#comments</comments>
		<pubDate>Tue, 07 Jul 2009 15:50:48 +0000</pubDate>
		<dc:creator>Duffy</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Debian]]></category>
		<category><![CDATA[disable]]></category>
		<category><![CDATA[ipv4]]></category>
		<category><![CDATA[ipv6]]></category>
		<category><![CDATA[networking]]></category>
		<category><![CDATA[tcp]]></category>
		<category><![CDATA[tutorial]]></category>

		<guid isPermaLink="false">http://tuts4tech.net/?p=458</guid>
		<description><![CDATA[If you don't use ivp6 for anything and your ISP doesn't support it theres not much of a need to have it enabled. To disable it we need to edit /etc/modprobe.d/aliases nano /etc/modprobe.d/aliases By default you will have the following line alias net-pf-10 ipv6 Replace it with the following alias net-pf-10 off alias ipv6 off [...]]]></description>
			<content:encoded><![CDATA[<p>If you don't use ivp6 for anything and your ISP doesn't support it theres not much of a need to have it enabled. To disable it we need to edit /etc/modprobe.d/aliases
<pre class="brush: bash;">nano /etc/modprobe.d/aliases</pre>
<p>By default you will have the following line
<pre class="brush: plain;">alias net-pf-10 ipv6</pre>
<p>Replace it with the following
<pre class="brush: plain;">alias net-pf-10 off
alias ipv6 off</pre>
<p>You can now remove all the ipv6 stuff from /etc/hosts and once you reboot ipv6 will be disabled</p>
]]></content:encoded>
			<wfw:commentRss>http://tuts4tech.net/2009/07/07/disabling-ipv6-on-debian/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Configuring LDAP Clients</title>
		<link>http://tuts4tech.net/2009/07/02/configuring-ldap-clients/</link>
		<comments>http://tuts4tech.net/2009/07/02/configuring-ldap-clients/#comments</comments>
		<pubDate>Thu, 02 Jul 2009 02:59:42 +0000</pubDate>
		<dc:creator>Duffy</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[auth]]></category>
		<category><![CDATA[clients]]></category>
		<category><![CDATA[howto]]></category>
		<category><![CDATA[ldap]]></category>
		<category><![CDATA[pam]]></category>
		<category><![CDATA[slapd]]></category>
		<category><![CDATA[tutorial]]></category>

		<guid isPermaLink="false">http://tuts4tech.net/?p=419</guid>
		<description><![CDATA[Install Needed Packages We need to install the following packages on our LDAP server apt-get install libnss-ldap libpam-ldap nscd LDAP Account for root: cn=admin,dc=home,dc=local Password: your-ldap-admin-password Make local root database admin: yes Database require logging in: No Root login account: cn=admin,dc=home,dc=local Root login password: your-ldap-admin-password Configuration Files /etc/libnss-ldap.conf nano /etc/libnss-ldap.conf host IP-OF-LDAP-SERVER base dc=home,dc=local bind_policy [...]]]></description>
			<content:encoded><![CDATA[<h3>Install Needed Packages</h3>
<ol>
<li>We need to install the following packages on our LDAP server
<pre class="brush: bash;">apt-get install libnss-ldap libpam-ldap nscd</pre>
<p>
<pre class="brush: plain;">LDAP Account for root: cn=admin,dc=home,dc=local
Password: your-ldap-admin-password
Make local root database admin: yes
Database require logging in: No
Root login account: cn=admin,dc=home,dc=local
Root login password: your-ldap-admin-password </pre>
</li>
</ol>
<p><span id="more-419"></span>
<ol>
<h3>Configuration Files</h3>
<li>/etc/libnss-ldap.conf
<pre class="brush: plain;">nano /etc/libnss-ldap.conf</pre>
<p>
<pre class="brush: plain;">host IP-OF-LDAP-SERVER
base dc=home,dc=local
bind_policy soft
rootbinddn cn=admin,dc=home,dc=local</pre>
</li>
<li>/etc/pam_ldap.conf
<pre class="brush: plain;">/etc/pam_ldap.conf</pre>
<p>
<pre class="brush: plain;">host IP-OF-LDAP-SERVER
base dc=home,dc=local
rootbinddn cn=admin,dc=home,dc=local</pre>
</li>
<li>Now we need to add pam_ldap so some of the pam configs
<pre class="brush: plain;">nano /etc/pam.d/common-account
account sufficient pam_ldap.so
account required pam_unix.so
#if you want user homedir to be created on first login
#session required pam_mkhomedir.so umask=0022 skel=/etc/skel/ silent

nano /etc/pam.d/common-auth
auth sufficient pam_ldap.so
auth required pam_unix.so nullok_secure use_first_pass

nano /etc/pam.d/common-password
password sufficient pam_ldap.so
password required pam_unix.so nullok obscure min=4 max=8 md5

nano /etc/pam.d/common-session
session sufficient pam_ldap.so
session required pam_unix.so
session optional pam_foreground.so</pre>
</li>
<li>Finally we need to edit /etc/nsswitch.conf
<pre class="brush: bash;">nano /etc/nsswitch.conf</pre>
<p>
<pre class="brush: plain;">passwd:         compat ldap
group:          compat ldap
shadow:         compat ldap</pre>
</li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://tuts4tech.net/2009/07/02/configuring-ldap-clients/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>How to sync 1Password</title>
		<link>http://tuts4tech.net/2009/06/30/how-to-sync-1password/</link>
		<comments>http://tuts4tech.net/2009/06/30/how-to-sync-1password/#comments</comments>
		<pubDate>Tue, 30 Jun 2009 16:18:24 +0000</pubDate>
		<dc:creator>Dave</dc:creator>
				<category><![CDATA[Misc]]></category>
		<category><![CDATA[dropbox]]></category>
		<category><![CDATA[mac]]></category>
		<category><![CDATA[password]]></category>
		<category><![CDATA[sync]]></category>
		<category><![CDATA[tutorial]]></category>

		<guid isPermaLink="false">http://tuts4tech.net/?p=396</guid>
		<description><![CDATA[Well this is more simple. Just download and install dropbox and use this url (yes its a referral but it gives you 0.25 gb extra) First go to 1Password in the menu then preferences then keychain then click move. Use something like this After that on your other computer do to First go to 1Password [...]]]></description>
			<content:encoded><![CDATA[<p><img class="alignnone" src="http://grabs.davek.ca/cce5e633d3aba07fc8a614d47d409534.png" alt="" width="584" height="452" /></p>
<p>Well this is more simple. Just download and install dropbox and use <a href="https://www.getdropbox.com/referrals/NTUzMTk4MDk">this url</a> (yes its a referral but it gives you 0.25 gb extra)</p>
<p>First go to 1Password in the menu then preferences then keychain then click move. Use something like this <img class="alignnone" src="http://grabs.davek.ca/e212c6c033fb62fce07e83daac765859.png" alt="" width="319" height="16" /></p>
<p>After that on your other computer do to First go to 1Password in the menu then prefs then keychain then move (Again). Go to your dropbox and pick the same file.</p>
]]></content:encoded>
			<wfw:commentRss>http://tuts4tech.net/2009/06/30/how-to-sync-1password/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Basic Batch Scripting</title>
		<link>http://tuts4tech.net/2009/06/24/basic-batch-scripting/</link>
		<comments>http://tuts4tech.net/2009/06/24/basic-batch-scripting/#comments</comments>
		<pubDate>Wed, 24 Jun 2009 15:51:26 +0000</pubDate>
		<dc:creator>Duffy</dc:creator>
				<category><![CDATA[Windows]]></category>
		<category><![CDATA[basic]]></category>
		<category><![CDATA[batch]]></category>
		<category><![CDATA[notepad]]></category>
		<category><![CDATA[scripting]]></category>
		<category><![CDATA[short]]></category>
		<category><![CDATA[tutorial]]></category>

		<guid isPermaLink="false">http://tuts4tech.net/?p=355</guid>
		<description><![CDATA[Introduction So first of all what is batch file? Its a file with a list of commands that are executed by command prompt(CMD) to open your cmd window go to start &#62; run &#62; cmd Basic Commands [batch]@echo off[/batch] This removes the "C:\Documents and Settings\Administrator&#62;" part [batch]cls[/batch] This clears all writing off the CMD window [...]]]></description>
			<content:encoded><![CDATA[<h3>Introduction</h3>
<p><img src="http://tuts4tech.net/wp-content/uploads/2009/06/cmd.jpg" alt="cmd" title="cmd" width="500" height="253" class="aligncenter size-full wp-image-577" /><br />
So first of all what is batch file? Its a file with a list of commands that are executed by command prompt(CMD) to open your cmd window go to start &gt; run &gt; cmd</p>
<h3>Basic Commands</h3>
<ol>
<li>
[batch]@echo off[/batch]<br />
This removes the "C:\Documents and Settings\Administrator&gt;" part</li>
<li>
[batch]cls[/batch]<br />
This clears all writing off the CMD window</li>
<li>
[batch]color backgroundcolor-textcolor[/batch]<br />
This allows you to change the color of the text</p>
<pre class="brush: plain;">0 = Black       8 = Gray
1 = Blue        9 = Light Blue
2 = Green       A = Light Green
3 = Aqua        B = Light Aqua
4 = Red         C = Light Red
5 = Purple      D = Light Purple
6 = Yellow      E = Light Yellow
7 = White       F = Bright White</pre>
<p>Example command:<br />
[batch]color 04[/batch]<br />
This example would give you red text on a black background</li>
<li>
[batch]goto TEXT[/batch]<br />
This will cause the script to go to a particular section of the script it will be explained more later on in this tutorial</li>
<li>
[batch]pause[/batch]<br />
This Pauses the command prompt and displays the message press any key to continue...</li>
</ol>
<p><span id="more-355"></span></p>
<h3>Your first batch script</h3>
<p>For this example we will make a simple hello world script.</p>
<p>To get started open up notepad start &gt; all programs &gt; accessories &gt; notepad<br />
[batch]@echo off<br />
color 64<br />
echo hello world<br />
pause[/batch]<br />
Save it with a .bat extension and then double click on it to run it. It should print the text "hello world" in red font on a yellow background and then pause</p>
<h3>The goto command</h3>
<p>The goto command tells the script to go to a certain part of it<br />
[batch]goto bush[/batch]<br />
this will cause the script to go to the line that starts with<br />
[batch]:bush[/batch]<br />
Example:<br />
[batch]@echo off<br />
echo Hello, this script will repeat the message "you will see this over and over again" to cancel it press ctrl+c<br />
pause<br />
:bush<br />
echo you will see this over and over again<br />
goto bush[/batch]<br />
The message was repeated because after it was printed the goto command made the script start again from :bush</p>
<h3>Launching programs from a batch script</h3>
<p>Using the start command we can start programs</p>
<p>Example:<br />
[batch]@echo off<br />
color f1<br />
echo this script will open google.com in your default internet browser<br />
pause<br />
start http://www.google.com[/batch]</p>
]]></content:encoded>
			<wfw:commentRss>http://tuts4tech.net/2009/06/24/basic-batch-scripting/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
