26 Kasım 2010 Cuma

How to disable IPv6 on Red Hat

Edit /etc/sysconfig/network and change

NETWORKING_IPV6=yes to

NETWORKING_IPV6=no

Edit /etc/modprobe.conf and add these lines (if they’re not in it):

alias net-pf-10 off

alias ipv6 off


Stop the ipv6tables service by typing:

service ip6tables stop

Disable the ipv6tables service by typing:

chkconfig ip6tables off

After these changes, IPv6 will be disabled after the next reboot of your system.

24 Kasım 2010 Çarşamba

how to determine PSP version



rpm –qa | grep hpacucli

22 Kasım 2010 Pazartesi

how to reset Cisco Pix 501 fw factory default

Use BREAK or ESC to interrupt flash boot.

Use SPACE to begin flash boot immediately.

Flash boot interrupted.                        

0: i8255X @ PCI(bus:0 dev:17 irq:9 )

1: i8255X @ PCI(bus:0 dev:18 irq:10)



Using 1: i82557 @ PCI(bus:0 dev:18 irq:10), MAC: 0008.a32b.89e6

Use ? for help.

monitor> address 192.168.1.1

address 192.168.1.1

monitor> file np63.bin

file np63.bin

monitor> server 192.168.1.35

server 192.168.1.35

monitor> timeout 1

timeout 1

monitor> ping 192.168.1.1

Sending 5, 100-byte 0xeb3c ICMP Echoes to 192.168.1.1, timeout is 1 seconds:



Success rate is 0 percent (0/5)

monitor>tftp



http://www.cisco.com/en/US/products/hw/vpndevc/ps2030/products_password_recovery09186a008009478b.shtml#pix_without 

20 Kasım 2010 Cumartesi

op5 monitor distributed setup

The setup

Introduction



In this setup we will have the following servers:

Poller server Master server

Hostname poller01 master

IP address 192.168.1.10 192.168.1.20

We now assume you have installed the OS and op5 Monitor on both servers.

Setting up the master

To setup your master server follow the steps bellow:





Step Instruction

1 Upload the master tar file to the master server and place it in

/root

2 Login, as the root user, via ssh.

3 Unpack the tar file and cd to the created folder:

tar xfvz op5_distributed_master-<VERSION>.tar.gz

cd distributed_master-<VERSION>/

4

Start the setup with:

./setup poller01 192.168.1.10

5 Type y or Y and press Enter to continue with the installation.

6 You will be prompted to tell the script if you like it to inactivate all

 active checks.

Y or y N or n

If you choose to let the script If you choose not to let the script

inactivate all active checks this inactivate you will have to do it

will not only affect the templates. your self after the setup is

Every host and service having finished.

enable_active_checks set will

have it set to 0.

1 - op5 Monitor distributed setup

The setup

Step Instruction

7 Choose whether to use PushLogs or not.

Setting up the poller - step one

To setup your poller server follow the instructions below:

Step Instruction

1 Upload the master tar file to the master server and place it in

/root

2 Login, as the root user, via ssh.

3 Unpack the tar file and cd to the created folder:

tar xfvz op5_distributed_poller-<VERSION>.tar.gz

cd distributed_poller-<VERSION>/

4

Star the setup with:

./setup poller01 192.168.1.10 192.168.1.20

5 Type y or Y and press Enter to continue with the installation.

6 Choose whether to use PushLogs or not.

Y or y

N or n

If you choose to use PushLogs

If you choose not to let the script

make sure you have enabled it on activate PushLogs for you will

the master server.

need to add everything manually

later if you change your mind.

7

Continue with Setting up the poller - step two.

Setting up the poller - step two

This part will guide you through the post setup part of the poller setup.

Step Instruction

1 Copy the ssh key printed by the setup script to the following file on the

 master server:

/opt/monitor/.ssh/authorized_keys

9

10

1 - op5 Monitor distributed setup

The setup

Step Instruction

2 Now su to the monitor user and make a test to login over ssh to the

 master server with the following commands:

su - monitor

ssh -i /etc/rsync/mirror-rsync-key 192.168.1.20

3

As the monitor user execute a manual conf sync with the following

two commands:

su - monitor

/opt/plugins/control/check_conf_sync.sh

4

Open up Configure in the monitor web GUI and remove the monitor

host object.

op5 custom

1.----

opt]# vi /opt/monitor/op5/ninja/application/controllers/ninja.php

op5 portal burda sol menudekini degistir.



2.----

ServerName https://10.x.x.x

Redirect permanent / http://www.xxxx.com/


i ekle httpd/conf.d/xxx.conf adi altinda. bu op5 portal linkini kaldiriyor







3.----

backup lar /root altina atiliyor



4.----

/opt/monitor/op5/ninja/application/views/themes/default/css/default/images/login.png

ahanda burda login ekranindaki logo



5.----

Lisans icin bu dosyadaki her satiri comment le. 

monitor/share/op5/ninja/application/addons/license/ninja_license.js



6.----

mail notification lar bu dizin altinda. 

/opt/monitor/op5/notify/skins.mail



7.----

/opt/monitor/op5/ninja/application/views/themes/default/icons/icon.png

bu icon kucuk logo icon. degistir telenitiy.icon.png ile



8.----

 16x16

/opt/monitor/op5/ninja/application/views/themes/default/icons/16x16/favicon.ico



9.----

/opt/monitor/op5/auto-reports/lib_mail.php

icinde schedule reports daki mail from op5Monitor u degistirebiilrsin.





10.----

Open your php.ini file

EDIT: max_execution_time = 120

Save and restart httpd



11.---- 

icinde op5 Monitor gecenler

/opt/monitor altinda

op5/reports/gui/sla/sla.php

op5/reports/gui/sla/index.php

op5/reports/gui/op5build/collax/build.in

op5/reports/gui/avail_setup.php

op5/ninja/application/views/themes/default/backup/list.php

op5/ninja/application/config/config.php

op5/auto-reports/autoreports.spec.in

op5/auto-reports/include/auto-reports.inc.php

op5/auto-reports/op5build/monitor-autoreports.list.in

op5/auto-reports/op5build/collax/build.in

op5/auto-reports/monitor-autoreports.spe

how to uninstall op5-monitor on redhat

yum remove mrtg monitor-config.i386  op5-dokuwiki.noarch op5auth.noarch op5backup.noarch  perl-DBD-Sybase.i386 perl-Device-Modem.noarch perl-Term-VT102.noarch plugins-community.i386 plugins-metadata.i386 plugins-nagios.i386 plugins-op5.i386  sendnsca.i386 webinject.noarch op5-monitor-repo-config.noarch op5-default.noarch op5common.noarch op5license.i386 smstools.i386 nrpe-client.i386 nrpe.i386



yada









yum remove op5-monitor-repo-config-5.0.3-op5.1.noarch  asterisk-1.4.4-op5.1_RHEL5.i386  op5-system-release-addons-3.5.0-op5.1.noarch  asterisk-devel-1.4.4-op5.1_RHEL5.i386  openvpn-2.0.9-1.el5.rf.i386  eventlog-0.2.5-8.i386  passwdgen-2.2-2.el5.rf.i386  git-core-1.5.3.8-1.i386   perl-Class-Accessor-0.34-1.el5.rf.noarch  graphviz-2.24.0-1.el5.i386  perl-Config-Tiny-2.12-1.el5.rf.noarch  graphviz-gd-2.24.0-1.el5.i386  perl-Crypt-DES-2.05-3.2.el5.rf.i386  jed-0.99.18-op5.6_RHEL5.i386  perl-Crypt-Rijndael-1.04-1.el5.rf.i386   libmhash-0.9.1-1.2.el5.rf.i386  perl-DBD-Sybase-1.07-op5.1_RHEL5.i386  libmhash-devel-0.9.1-1.2.el5.rf.i386  perl-Device-Modem-1.48-op5.1.noarch  lzo2-2.02-3.el5.rf.i386  perl-Device-SerialPort-1.003001-1.el5.rf.i386   merlin-0.6.8-op5.1.i386  perl-Email-Simple-2.003-1.el4.rf.noarch  mm-1.4.0-op5.1_RHEL5.i386  perl-Error-0.17016-1.el5.rf.noarch   mm-devel-1.4.0-op5.1_RHEL5.i386  perl-Expect-1.21-1.el5.rf.noarch  monitor-4.0.9-op5.1.i386  perl-Git-1.5.3.8-1.i386  monitor-autoreports-2.1.4-op5.1.noarch  perl-IO-Stty-.02-1.2.el5.rf.noarch  monitor-backup-3.2.8-op5.1.i386  perl-IO-Tty-1.08-1.el5.rf.i386  monitor-config-3.4.6-op5.1.i386  perl-Math-Calc-Units-1.07-1.el5.rf.noarch  monitor-gui-3.5.8-op5.1.i386  perl-Nagios-Plugin-0.33-1.el5.rf.noarch  monitor-gui-core-4.0.9-op5.1.i386  perl-Net-SMTP-SSL-1.01-1.el5.rf.noarch  monitor-merlin-0.6.8-op5.1.i386  perl-Net-SNMP-5.2.0-1.2.el5.rf.noarch  monitor-nacoma-4.0.13-op5.1.noarch  perl-Params-Validate-0.91-1.el5.rf.i386  monitor-nagvis-1.4.1.4-op5.1.noarch  perl-rrdtool-1.3.8-2.el5.rf.i386  monitor-networkmap-3.3.4-op5.1.noarch  perl-Term-VT102-0.82-op5.1.noarch  monitor-ninja-1.0.3-op5.1.i386  plugins-community-2.6.2-op5.1.i386  monitor-notify-3.3.5-op5.1.noarch  plugins-metadata-2.6.1-op5.1.i386  monitor-op5auth-1.1.4-op5.1.noarch  plugins-nagios-2.4.1-op5.1.i386  monitor-passive-3.0.9-op5.1.noarch  plugins-op5-2.6.2-op5.1.i386  monitor-pnp-0.4.12.5-op5.1.i386  portal-1.6.0-op5.1.noarch  monitor-reports-gui-1.4.8-op5.1.i386  radiusclient-0.3.2-0.2.el5.rf.i386  monitor-reports-module-2.0.10-op5.1.i386   radiusclient-devel-0.3.2-0.2.el5.rf.i386  nrpe-2.7.0-op5.3_RHEL5.i386  redhat nrpe-client-2.10.2-op5.1.i386  rrdtool-1.3.8-2.el5.rf.i386  nsca-2.6.0-op5.3_RHEL5.i386  rrdtool-devel-1.3.8-2.el5.rf.i386  op5auth-1.2.0-op5.1.noarch  sendnsca-2.6.0-op5.3_RHEL5.i386  op5backup-2.0.0-op5.1.noarch  smsacknowledge-1.2.2-op5.1.noarch  op5common-1.1.10-op5.1.noarch  smspassivecheck-1.2.1-op5.1.noarch  op5-default-3.1.2-op5.1.noarch  smsreceiver-1.2.1-op5.1.noarch  op5-dokuwiki-1.4.3-op5.1.noarch  smstools-2.2.18-op5.4_RHEL5.i386  op5license-1.3.1-op5.1.i386  webinject-1.41-op5.1_RHEL5.noarch  op5-monitor-release-5.0.3-op5.1.noarch

19 Kasım 2010 Cuma

Redirect all requests to https://...

# Redirect all requests to https://...

<IfModule mod_rewrite.c>

    RewriteEngine On

        RewriteRule ^/(.*)$ https://%{SERVER_NAME}/$1 [R]

</IfModule>

17 Kasım 2010 Çarşamba

8540w with ubuntu #1

This workaround fixes the problem for me:

create files : /etc/pm/config.d/00sleep_module and /etc/pm/config.d/unload_module

add line to files : SUSPEND_MODULES="xhci-hcd"

8540w with ubuntu suspend problem #1

This workaround fixes the problem for me:

create files : /etc/pm/config.d/00sleep_module and /etc/pm/config.d/unload_module

add line to files : SUSPEND_MODULES="xhci-hcd"

12 Kasım 2010 Cuma

convert ogv video to avi on ubuntu

mencoder -idx input.ogv -ovc lavc -oac mp3lame -o output.avi

or

ffmpeg -i input.ogv output.mpg

11 Kasım 2010 Perşembe

How to restrict vsftpd users only to the their home directory?

On my linux fedora5 box vsftpd is working, I just want to restrict all users only to their home directory. Problem is if I comment out

#chroot_list_enable=YES    and put  

chroot_local_user=YES




than add the username into file named  /etc/vsftpd/chroot_list

3 Kasım 2010 Çarşamba

1 Kasım 2010 Pazartesi

Extend LVM Disk Space With New Hard Disk

Extend LVM Disk Space With New Hard Disk



Copyright © Walker 27 Feb 2007 23:56



This is a step-by-step guide used to extend logical volume group disk space, that’s configured under LVM version 1.x of Redhat Enterprise Linux AS 3. Although, this guide has also been used to extend LVM disk space with a new SCSI hard disk, that’s configured with LVM version 2.x in Debian Sarge 3.1.











So, it’s good enough to serve as a reference for Linux users, who plan to extend LVM disk space in Linux distributions other than Redhat and Debian Linux.



Although it’s not necessary, it’s advised to perform full file system backup before carry out this exercise!



The most risky step is to resize file system that resides in a LVM logical volume. Make sure the right file system resizer tool is used. If you’re using resize2fs to resize a Reiserfs file system, I guess you’ll know how bad will be the consequences.



Apparently, you’ll need resize_reiserfs to resize a Reiserfs file system, which is part of the reiserfsprogs package.



Steps to extend /home file system that mounts on logical volume /dev/vg0/lvol1 of volume group vg0, by using a new 36GB SCSI hard disk added to RAID 0 of HP Smart Array 5i Controller.

1) Log in as root user and type init 0 to shutdown Redhat Enterprise AS 3 Linux.

2) Add in the new 36GB SCSI hard disk. Since HP Smart Array 5i is configure for RAID 0, it’s fine to mix hard disks of different capacity, except that hard disk speed must be the same! A mix of 10K and 15K RPM hard disks might cause Redhat Enterprise Linux fails to boot up properly.

Normally, HP Smart Array 5i Controller will automatically configure new hard disk as a logical drive for RAID 0. If not, press F8 on boot up to get in HP Smart Array 5i Controller setup screen and manually create logical drive as part of RAID 0.



How to tell if new hard disk is not configured as logical drive for RAID 0?

Physically, the hard disk green light should be on or blinking to indicate that it’s online to RAID system.

From OS level, 3rd hard disk in RAID 0 of HP Smart Array 5i Controller is denoted as /dev/cciss/c0d2. So, type



fdisk /dev/cciss/c0d2



at root command prompt. If an error message Unable to open /dev/cciss/c0d2 or alike is returned, it means that new hard disk is not online to RAID system or Redhat Linux.



3) Boot up Redhat Enterprise Linux into multi-user mode and confirm it’s working properly. This step is not necessary, but it’s a good practice to prove that the server is working fine after each change has been made, be it a major or minor change.



4) Type init 1 at root command prompt to boot into single user mode. Whenever possible, boot into single user mode for system maintenance as to avoid inconsistency or corruption.



5) At the root command prompt, type



fdisk /dev/cciss/c0d2



to create partition for the 3rd SCSI hard disk added to RAID 0. Each hard disk needs at least one partition (maximum 4 primary partitions per hard disk) in order to use the new hard disk in a Linux system.



6) While at the fdisk command prompt, type m to view fdisk command options.



7) Type n to add a new partition, followed by p to go for primary partition type.



8) Type 1 to create the first partition. Press ENTER to accept first cylinder default as 1, and press ENTER again to accept the default value for last cylinder, which is essentially create single partition that use up all hard disk space.



9) Type t to change the partition system id, or partition type. As there is only one partition, partition 1 is automatically selected for action. Type L to list all supported partition type. As shown in partition type listing, type 8e to set partition 1 as Linux LVM partition type.

10) Type p to confirm partition /dev/cciss/c0d2p1 has been created in partition table. Type w to write the unsaved partition table of changes to hard disk and exit from fdisk command line.

11) Type df -hTa to confirm /home file system type, that’s mounts on logical volume /dev/vg0/lvol1. For this case, it’s an ext3 file system type.

12) Type umount /home to un-mount /home file system from Redhat Enterprise Linux.

13) Next, type LVM command

pvcreate /dev/cciss/c0d2p1

to create a new LVM physical volume on the new partition /dev/cciss/c0d2p1.

14) Now, type another LVM command

vgextend vg0 /dev/cciss/c0d2p1

to extend LVM volume group vg0, with that new LVM physical volume created on partition /dev/cciss/c0d2p1.

15) Type pvscan to display physical volumes created in Linux LVM system, which is useful to answer questions such as “How many physical volume created in volume group vg0?”, “How much of free disk space left on each physical volume?”, “How do I know which physical volume should be used for a logical volume?” “Which physical volume has free disk space for used with a logical volume?”, etc.

Sample output of pvscan command:

ACTIVE PV “/dev/cciss/c0d0p4″ of VG “vg0″ [274.27GB / 0 free]

ACTIVE PV “/dev/cciss/c0d1p1″ of VG “vg0″ [33.89GB / 0 free]

ACTIVE PV “/dev/cciss/c0d2p1″ of VG “vg0″ [33.89 GB / 33.89 GB free]

total: 3 [342.05 GB] / in use: 3 [342.05 GB] / in no VG: 0 [0]

Alternative, type vgdisplay vg0 | grep PE to confirm that new physical volume has been added to volume group vg0. Take note ofFree PE / Size, 35GB in this case, that’s free disk space added by new physical volume in volume group vg0.

16) Execute LVM command

lvextend -L +33G /dev/vg0/lvol1 /dev/cciss/c0d2p1

to extend the size of logical volume /dev/vg0/lvol1 of volume group vg0 by 33GB on physical volume /dev/cciss/c0d2p1.

17) Now, the most risky steps to start. Type this command

e2fsck -f /dev/vg0/lvol1

to force ext3 file system check on /dev/vg0/lvol1. It’s a must to confirm file system is in good state, before implement any changes on it.

CAUTION – Utility e2fsck is only used to check EXT file system such as ext2 and ext3, and not other file system such Reiserfs file system!

Once the ext file system check completes without errors or warnings, type command

resize2fs /dev/vg0/lvol1

to resize EXT3 file system of /home, that mounts on logical volume /dev/vg0/lvol1, until it takes up all free disk space added to /dev/vg0/lvol1.

CAUTION – Utility resize2fs is only used to resize EXT file system such as ext2 and ext3, and not other file systems such as Reiserfs file system!

Both e2fsck and resize2fs utilities are part of e2fsprogs package. And both utilities takes some minutes to complete, depends on the size of target file system.

If everything alright, type mount /home to re-mount /home file system. Next, type df -h to confirm that /home file system has been extended successfully.

Change Time Zone on Linux

system-config-date or system-config-date



Do not check UTC 



zic /tzdata/asia



zic -l Asia/Jerusalem