January 26, 2012 at 10:35 am
· Filed under Uncategorized
You might be saying that IPv6 is the bees knees, and I must be crazy for wanting to disable it. Well that is partially true. In this case I need to disable it because my machinne is on a network that can only handle IPv4 packets. It also slowed down connections on the machine because of how the network was set up. So basically it was necessary in order to speed up the networking on the server.
add the “options single-request” to the /etc/resolv.conf file
nameserver 4.2.2.1
nameserver 4.2.2.2
options single-request
add “NETWORKING_IPV6=off” to /etc/sysconfig/network
NETWORKING_IPV6=off
next edit the /etc/modprobe.d/ECS.conf file and add “alias ipv6 off” and “net-pf-10″
alias ipv6 off
alias net-pf-10 off
remove the running module
# rmmod ipv6
Then restart network by
# service network restart
or reboot to box to make sure it works after a reboot with
# reboot
To test to make sure that the changes have worked, you should not get anything returned
# lsmod | grep ipv6
You can also run “ifconfig -a” and make sure you do not see the fowling
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
should see
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:16436 Metric:1
Permalink
July 21, 2011 at 11:22 am
· Filed under Uncategorized
For some reason my new CentOS install has a working ssh but I could not find any scp.
So the package that contains openssh-clients
[root@localhost ~]# whereis scp
scp:
[root@localhost ~]# yum install openssh-clients
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
* base: mirrors.seas.harvard.edu
* epel: mirror.cogentco.com
* extras: centos.mirror.nac.net
* updates: mirrors.seas.harvard.edu
Setting up Install Process
Resolving Dependencies
–> Running transaction check
—> Package openssh-clients.x86_64 0:5.3p1-20.el6_0.3 set to be updated
–> Processing Dependency: libedit.so.0()(64bit) for package: openssh-clients-5.3p1-20.el6_0.3.x86_64
–> Running transaction check
—> Package libedit.x86_64 0:2.11-4.20080712cvs.1.el6 set to be updated
–> Finished Dependency Resolution
Dependencies Resolved
===================================================================================================================================================================================
Package Arch Version Repository Size
===================================================================================================================================================================================
Installing:
openssh-clients x86_64 5.3p1-20.el6_0.3 updates 351 k
Installing for dependencies:
libedit x86_64 2.11-4.20080712cvs.1.el6 base 74 k
Transaction Summary
===================================================================================================================================================================================
Install 2 Package(s)
Upgrade 0 Package(s)
Total download size: 425 k
Installed size: 1.2 M
Is this ok [y/N]: y
Downloading Packages:
(1/2): libedit-2.11-4.20080712cvs.1.el6.x86_64.rpm | 74 kB 00:00
(2/2): openssh-clients-5.3p1-20.el6_0.3.x86_64.rpm | 351 kB 00:00
———————————————————————————————————————————————————————————–
Total 1.0 MB/s | 425 kB 00:00
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
Installing : libedit-2.11-4.20080712cvs.1.el6.x86_64 1/2
Installing : openssh-clients-5.3p1-20.el6_0.3.x86_64 2/2
Installed:
openssh-clients.x86_64 0:5.3p1-20.el6_0.3
Dependency Installed:
libedit.x86_64 0:2.11-4.20080712cvs.1.el6
Complete!
[root@localhost ~]# whereis scp
scp: /usr/bin/scp /usr/share/man/man1/scp.1.gz
Permalink
August 30, 2010 at 10:36 am
· Filed under Uncategorized
If you have Apache directories that you want only certain IP to be able to access. Say you have a management interface that you only want employees to have access to.
Once you have properly put the fowling code into
/etc/apache2/sites-available/default
and you are not comming from one of the allowed IP you will be greated with a page that says.
Forbidden
You don’t have permission to access /directory/onwebserver/index.php on this server.
Otherwise the normal web page will show up.
<Directory /var/www/super/secret/>
order deny,allow
deny from all
allow from 10.10.0.100 192.168.77.44
</Directory>
Permalink