Posts Tagged ‘CentOS’

How to disable the iptables firewall in Linux

November 2nd, 2010

while doing the MySQL Cluster Set up I needed to disable the firewall on the linux  so sharing how to do that

To Disable Firewall (Red hat/CentOS/Fedora Core)

/etc/init.d/iptables save
/etc/init.d/iptables stop

To Enable  Firewall (Red hat/CentOS/Fedora Core)

Type the following command to turn on iptables firewall:
/etc/init.d/iptables start

Tomcat 6 installation on CentOS 5/RHEL

August 25th, 2010

We can add repository under /etc/yum.repos.d/
wget ‘http://www.jpackage.org/jpackage50.repo’

#rpm -Uvh ‘http://plone.lucidsolutions.co.nz/linux/centos/images/jpackage-utils-compat-el5-0.0.1-1.noarch.rpm

#yum update
# yum install tomcat6 tomcat6-webapps tomcat6-admin-webapps
# service tomcat6 start

SVN installation with Apache

August 13th, 2010

1. First of all, install apache/httpd
* yum install httpd
2. Make sure you apache is running. You can also type ‘http://localhost’ at your browser and apache test page should appear if your apache is running
* /etc/init.d/httpd status
3. Make it start by default on startup
* chkconfig httpd on
4. Edit the apache configuration to suit your need. If not sure, leave the default setting as it is
* vi /etc/httpd/conf/httpd.conf
5. Install subversion and mod_dav_svn for apache
* yum install mod_dav_svn subversion
6. Go to subversion.conf in /etc/httpd/conf.d/. Edit as below
* cd /etc/httpd/conf.d/
* vi subversion.conf

1. This is the most basic configuration where anyone will have unrestricted access to the repos. Location is the name that will be used in the browser address bar. In this example it will be ‘http://localhost/svn/repos’

2. This is a configuration with username and password for the client

DAV svn

SVNListParentPath on

SVNParentPath /usr/local/svn/

AuthType Basic

AuthName “Subversion repositories”

AuthUserFile “/etc/httpd/conf.d/svnuserconf”

Require valid-user

1.
* htpasswd -cm /etc/httpd/conf.d/svnuserconf admin — This command is not needed for the first configuration. To create the first user with password
* htpasswd -m /etc/httpd/conf.d/svnuserconf pawan — use this command to add another user
2. Configure your repository
* mkdir /usr/local/svn — create folder svn
* cd /usr/local/svn — change diectory to the newly created svn directory
* svnadmin create repos — create svn repository named repos
* chown apache.apache -R repos — change ownership of ‘repos’ to apache
* /etc/init.d/httpd restart — restart apache
* If you are running different apache change port no from conf file.
3. Open you browser and type ‘http://localhost/svn/repos’. You can see that a page with ‘Revision 0:/’ will appear. Congratulation, you just completed the setup for svn server

Method of Joinig Active Directory from a Linux machine

April 16th, 2010

#net join -w -S -I -U administrator

Now it will ask for Active Directory administrator password

Verifying the Results, we can verify the using

#wbinfo -u
will give all the users in Active Directory
#wbinfo -g
will give all the ou and groups information

Thanks
Pawan Kumar