although you do an xhost + still you cannot do an xclock so:
on the machine connecting to the other do a
vi /etc/X11/gdm/gdm.com
DisallowTCP=false
** REMEMBER to check iptables
Wednesday, February 27, 2008
Tuesday, February 26, 2008
Sunday, February 24, 2008
Oracle Move from one computer/directory to another
1. Edit and replace paths in
/etc/oratab
/etc/rc.d/rc5.d/S99zzoracle_orasid
/etc/rc.d/init.d/orastop_orasid
/etc/rc.d/init.d/listener_orasid
/etc/rc.d/init.d/orastart_orasid
/etc/rc.d/rc6.d/K10zzoracle_orasid
/etc/rc.d/rc0.d/K10zzoracle_orasid
/etc/rc.d/rc3.d/S99zzoracle_orasid
/etc/rc.d/rc1.d/K10zzoracle_orasid
/etc/oraInst.loc
2. Edit and replace paths in
listener.ora tnsnames.ora
3. login as sys as sysdba (listener must be on and database mounted)
create pfile='/apps/oracle/OraHome1/dbs/initorasid.ora' from spfile='/apps/oracle/OraHome1/dbs/spfileorasid.ora'
4. Edit /apps/oracle/OraHome1/dbs/initorasid.ora and change paths
5. Now do the reverse
create spfile='/apps/oracle/OraHome1/dbs/spfileorasid.ora' from pfile='/apps/oracle/OraHome1/dbs/initorasid.ora'
6. The last step is to alter internal files names:
alter database rename file '/home/gf_admin/oradata/gftt/control01.ctl' to '/apps/gf_admin/oradata/gftt/control01.ctl';
alter database rename file '/home/gf_admin/oradata/gftt/control02.ctl' to '/apps/gf_admin/oradata/gftt/control02.ctl';
alter database rename file '/home/gf_admin/oradata/gftt/control03.ctl' to '/apps/gf_admin/oradata/gftt/control03.ctl';
alter database rename file '/home/gf_admin/oradata/gftt/redo01.log' to '/apps/gf_admin/oradata/gftt/redo01.log';
alter database rename file '/home/gf_admin/oradata/gftt/redo02.log' to '/apps/gf_admin/oradata/gftt/redo02.log';
alter database rename file '/home/gf_admin/oradata/gftt/redo03.log' to '/apps/gf_admin/oradata/gftt/redo03.log';
alter database rename file '/home/gf_admin/oradata/gftt/system.dbf' to '/apps/gf_admin/oradata/gftt/system.dbf';
alter database rename file '/home/gf_admin/oradata/gftt/temp.dbf' to '/apps/gf_admin/oradata/gftt/temp.dbf';
alter database rename file '/home/gf_admin/oradata/gftt/tsdata.dbf' to '/apps/gf_admin/oradata/gftt/tsdata.dbf';
alter database rename file '/home/gf_admin/oradata/gftt/tsindex.dbf' to '/apps/gf_admin/oradata/gftt/tsindex.dbf';
alter database rename file '/home/gf_admin/oradata/gftt/undotbs.dbf' to '/apps/gf_admin/oradata/gftt/undotbs.dbf';
/etc/oratab
/etc/rc.d/rc5.d/S99zzoracle_orasid
/etc/rc.d/init.d/orastop_orasid
/etc/rc.d/init.d/listener_orasid
/etc/rc.d/init.d/orastart_orasid
/etc/rc.d/rc6.d/K10zzoracle_orasid
/etc/rc.d/rc0.d/K10zzoracle_orasid
/etc/rc.d/rc3.d/S99zzoracle_orasid
/etc/rc.d/rc1.d/K10zzoracle_orasid
/etc/oraInst.loc
2. Edit and replace paths in
listener.ora tnsnames.ora
3. login as sys as sysdba (listener must be on and database mounted)
create pfile='/apps/oracle/OraHome1/dbs/initorasid.ora' from spfile='/apps/oracle/OraHome1/dbs/spfileorasid.ora'
4. Edit /apps/oracle/OraHome1/dbs/initorasid.ora and change paths
5. Now do the reverse
create spfile='/apps/oracle/OraHome1/dbs/spfileorasid.ora' from pfile='/apps/oracle/OraHome1/dbs/initorasid.ora'
6. The last step is to alter internal files names:
alter database rename file '/home/gf_admin/oradata/gftt/control01.ctl' to '/apps/gf_admin/oradata/gftt/control01.ctl';
alter database rename file '/home/gf_admin/oradata/gftt/control02.ctl' to '/apps/gf_admin/oradata/gftt/control02.ctl';
alter database rename file '/home/gf_admin/oradata/gftt/control03.ctl' to '/apps/gf_admin/oradata/gftt/control03.ctl';
alter database rename file '/home/gf_admin/oradata/gftt/redo01.log' to '/apps/gf_admin/oradata/gftt/redo01.log';
alter database rename file '/home/gf_admin/oradata/gftt/redo02.log' to '/apps/gf_admin/oradata/gftt/redo02.log';
alter database rename file '/home/gf_admin/oradata/gftt/redo03.log' to '/apps/gf_admin/oradata/gftt/redo03.log';
alter database rename file '/home/gf_admin/oradata/gftt/system.dbf' to '/apps/gf_admin/oradata/gftt/system.dbf';
alter database rename file '/home/gf_admin/oradata/gftt/temp.dbf' to '/apps/gf_admin/oradata/gftt/temp.dbf';
alter database rename file '/home/gf_admin/oradata/gftt/tsdata.dbf' to '/apps/gf_admin/oradata/gftt/tsdata.dbf';
alter database rename file '/home/gf_admin/oradata/gftt/tsindex.dbf' to '/apps/gf_admin/oradata/gftt/tsindex.dbf';
alter database rename file '/home/gf_admin/oradata/gftt/undotbs.dbf' to '/apps/gf_admin/oradata/gftt/undotbs.dbf';
Saturday, February 23, 2008
oracle spfile and pfile
startup using spfile
STARTUP
startup using pfile
STARTUP PFILE=’C:\oracle\product\10.2.0\admin\MarlonDB\initMarlonDB01.ora’
convert one to another:
CREATE SPFILE=’C:\oracle\product\10.2.0\db_1\database\spfileMarlonDB01.ora’ FROM PFILE=’C:\oracle\product\10.2.0\admin\MarlonDB\initMarlonDB01.ora’;
CREATE PFILE=’C:\oracle\product\10.2.0\admin\MarlonDB\initMarlonDB01.ora’ FROM SPFILE=’C:\oracle\product\10.2.0\db_1\database\spfileMarlonDB01.ora’;
STARTUP
startup using pfile
STARTUP PFILE=’C:\oracle\product\10.2.0\admin\MarlonDB\initMarlonDB01.ora’
convert one to another:
CREATE SPFILE=’C:\oracle\product\10.2.0\db_1\database\spfileMarlonDB01.ora’ FROM PFILE=’C:\oracle\product\10.2.0\admin\MarlonDB\initMarlonDB01.ora’;
CREATE PFILE=’C:\oracle\product\10.2.0\admin\MarlonDB\initMarlonDB01.ora’ FROM SPFILE=’C:\oracle\product\10.2.0\db_1\database\spfileMarlonDB01.ora’;
Saturday, February 16, 2008
linux increase swap
mkdir /opt
dd if=/dev/zero of=swapfile01 bs=1024M count=1
mkswap swapfile01
swapon swapfile01
vi /etc/fstab
/opt/swapfile01 swap swap defaults 0 0
dd if=/dev/zero of=swapfile01 bs=1024M count=1
mkswap swapfile01
swapon swapfile01
vi /etc/fstab
/opt/swapfile01 swap swap defaults 0 0
Thursday, February 14, 2008
oracle 9i export
if exporting from an oracle 9 instance ended in error you have to run $ORACLE_HOME/rdbms/admin/catexp.sql first.
Thursday, February 07, 2008
connect to network resources on another domain
To connect to network resources in form of \\server\share on a computer which is a member of a domain other than the one you are and when you get "There are currently no logon servers available to service your request" error, do the following
1. You should know the exact share name on the server that you are connecting to.
2. explorer->Tools->Map network drive
3. specify the share name
4. user other username and password
5. Specify DOMAIN_NAME\username as username
1. You should know the exact share name on the server that you are connecting to.
2. explorer->Tools->Map network drive
3. specify the share name
4. user other username and password
5. Specify DOMAIN_NAME\username as username
Tuesday, February 05, 2008
whenever you come accros this.....
symbol errno, version GLIBC_2.0 not defined in file libc.so.6 with link time reference
you have to set LD_ASSUME_KERNEL=2.4.1 in the environment of whatever user trying to run Oracle tools like dbca
you have to set LD_ASSUME_KERNEL=2.4.1 in the environment of whatever user trying to run Oracle tools like dbca
Wednesday, January 30, 2008
Ubuntu as nis client for Solaris
Since YP reports map files from Solaris to have dots like auto.master instead of underscores like auto_master; /etc/init.d/autofs must be changed to replace underscores with dot just like REDHAT.
a varible UNDERSCORETODOT=1 is added under the debian section and when the value is checked I replceed the below statement
map=`basename $map | sed -e s/^auto_home/auto.home/ -e s/^auto_mnt/auto.mnt/`
with
map=`basename $map | sed -e s/auto_/auto./g`
now all underscores are converted into dots.
a varible UNDERSCORETODOT=1 is added under the debian section and when the value is checked I replceed the below statement
map=`basename $map | sed -e s/^auto_home/auto.home/ -e s/^auto_mnt/auto.mnt/`
with
map=`basename $map | sed -e s/auto_/auto./g`
now all underscores are converted into dots.
Monday, January 28, 2008
Monday, January 07, 2008
ethernet conenction bonding RHEL
This one works
http://www.howtoforge.com/network_card_bonding_centos
http://www.howtoforge.com/network_card_bonding_centos
Sunday, January 06, 2008
Saturday, January 05, 2008
Solaris Automount NFS with linux clients
Solaris Box:
0. /et/defaultdomain :: Put NIS domain name here
1. vi /etc/dfs/dfstab
share -F nfs -o rw /apps1
share -F nfs -o rw /home1
share -F nfs -o rw /data
2. vi /etc/auto_master
/apps1 auto_apps -nosuid,nobrowse
3. vi /etc/auto_apps
oracle -ro s2:/apps1/oracle
gf_admin -rw s2:/apps1/gf_admin
4. vi /var/yp/Makefile
Copy the section auto_home and auto.home and create corresponding auto_apps and auto.apps sections
5. make
6. *TO DO*: to prevent the NIS server from automounting its own directories and consecutively not seeing the contents of those - falsely automounted - directories I removed the "files nis" tags in front of automount in /etc/nssswitch.conf
Linux Box:
7. /etc/sysconfig/network :: put NISDOMAIN=$nisdomainname
8. /etc/yp.bind :: specify server and NIS Domain name
0. /et/defaultdomain :: Put NIS domain name here
1. vi /etc/dfs/dfstab
share -F nfs -o rw /apps1
share -F nfs -o rw /home1
share -F nfs -o rw /data
2. vi /etc/auto_master
/apps1 auto_apps -nosuid,nobrowse
3. vi /etc/auto_apps
oracle -ro s2:/apps1/oracle
gf_admin -rw s2:/apps1/gf_admin
4. vi /var/yp/Makefile
Copy the section auto_home and auto.home and create corresponding auto_apps and auto.apps sections
5. make
6. *TO DO*: to prevent the NIS server from automounting its own directories and consecutively not seeing the contents of those - falsely automounted - directories I removed the "files nis" tags in front of automount in /etc/nssswitch.conf
Linux Box:
7. /etc/sysconfig/network :: put NISDOMAIN=$nisdomainname
8. /etc/yp.bind :: specify server and NIS Domain name
Wednesday, December 26, 2007
Password proetct pages in Apache
create a password encoded .httaccess file with
http://www.4webhelp.net/us/password.php
http://shop.alterlinks.com/htpasswd/htpasswd.php
http://www.htmlite.com/HTA006a.php
in form of user:encoded_password
then add the following to corerct section in httpd.conf file
AuthUserFile /full/path/to/.htaccess
AuthType Basic
AuthName "Authorization Required"
Require valid-user
restart apache
http://www.4webhelp.net/us/password.php
http://shop.alterlinks.com/htpasswd/htpasswd.php
http://www.htmlite.com/HTA006a.php
in form of user:encoded_password
then add the following to corerct
AuthUserFile /full/path/to/.htaccess
AuthType Basic
AuthName "Authorization Required"
Require valid-user
restart apache
Monday, December 24, 2007
Cacti on Windows
The following have to be set in the cacti->settings
PATH
spine path is to be set
rrdtool font is to be set like c:/cacti/arial.ttf
GENERAL
RRDTOOL version must match the installed rrdtool
PATH
spine path is to be set
rrdtool font is to be set like c:/cacti/arial.ttf
GENERAL
RRDTOOL version must match the installed rrdtool
Saturday, December 15, 2007
NIS AUTOMOUNT
1. server: /etc/exports, define exportable directories
/users *(rw,no_root_squash,no_all_squash,sync)
/apps *(ro,sync)
2. server: service nfs restart
3. server: /var/yp/Makefile, edit to include auto.* in make all
(YP server is to be installed first)
4. server: /etc/auto.master :: <--- REMEMBER NO /etc in front of auto.*
/users auto.home --ghost
/apps auto.local --ghost
5. server: /etc/auto.home ::
* -rw dcssrv4:/users/&
6. server: /etc/auto.local ::
oracle -ro dcssrv4:/apps/oracle
gf_admin -ro dcssrv4:/apps/gf_admin
7. server: cd /var/yp;make
8. server: service ypserv restart
9. client: edit /etc/nsswitch.conf :: automount nis files
10. client /etc/sysconfig/network :: put NISDOMAIN=xxxxxxx
11. client /etc/yp.conf :: put domain NISDOMAIN server XXXX
12. client: service ypbind restart & service autofs restart
look at http://penguin.triumf.ca/recipes/nis-auto/index.html
(it has an error, check the instrucion #4 above)
/users *(rw,no_root_squash,no_all_squash,sync)
/apps *(ro,sync)
2. server: service nfs restart
3. server: /var/yp/Makefile, edit to include auto.* in make all
(YP server is to be installed first)
4. server: /etc/auto.master :: <--- REMEMBER NO /etc in front of auto.*
/users auto.home --ghost
/apps auto.local --ghost
5. server: /etc/auto.home ::
* -rw dcssrv4:/users/&
6. server: /etc/auto.local ::
oracle -ro dcssrv4:/apps/oracle
gf_admin -ro dcssrv4:/apps/gf_admin
7. server: cd /var/yp;make
8. server: service ypserv restart
9. client: edit /etc/nsswitch.conf :: automount nis files
10. client /etc/sysconfig/network :: put NISDOMAIN=xxxxxxx
11. client /etc/yp.conf :: put domain NISDOMAIN server XXXX
12. client: service ypbind restart & service autofs restart
look at http://penguin.triumf.ca/recipes/nis-auto/index.html
(it has an error, check the instrucion #4 above)
Wednesday, December 12, 2007
Tuesday, December 11, 2007
qemu resize image file
1. qemu-img convert system.qcow -O raw system.raw
2. dd if=/dev/zero of=system.raw seek=N obs=1GB count=0 (N=final size)
3. qemu-img convert system.raw -O qcow growed-system.qcow
2. dd if=/dev/zero of=system.raw seek=N obs=1GB count=0 (N=final size)
3. qemu-img convert system.raw -O qcow growed-system.qcow
Monday, December 10, 2007
QEMU change cdrom
1. start qemu with -monitor stdio option along with other options
2. press CTRL+ALT+2 to enter CLI mode and CTRL+ALT+1 to exit
3. enter command "change cdrom isofilename.iso"
2. press CTRL+ALT+2 to enter CLI mode and CTRL+ALT+1 to exit
3. enter command "change cdrom isofilename.iso"
Sunday, December 09, 2007
remember you stupid that
files that start with . (dot) in linux will be hidden from plain ls, Gnome deskop,...
Subscribe to:
Posts (Atom)