Tuesday, August 27, 2013

Linux Server Oracle SQL Browser Connect

If you can't connect with Server IP Address , username and password make sure
2 or more ports need to unblock by firewall of server pc

Wednesday, August 21, 2013

Linux View IP Address

[root@localhost home]# ifconfig
eth0      Link encap:Ethernet  HWaddr 00:26:B9:1D:08:B7
          UP BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)
          Interrupt:31

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
          RX packets:1492 errors:0 dropped:0 overruns:0 frame:0
          TX packets:1492 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:131484 (128.4 KiB)  TX bytes:131484 (128.4 KiB)

virbr0    Link encap:Ethernet  HWaddr 86:A1:CA:B4:17:93
          inet addr:192.168.122.1  Bcast:192.168.122.255  Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:26 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:0 (0.0 b)  TX bytes:4363 (4.2 KiB)

wlan0     Link encap:Ethernet  HWaddr 00:17:C4:E1:C7:A4
          inet addr:192.168.1.104  Bcast:192.168.1.255  Mask:255.255.255.0
          inet6 addr: fe80::217:c4ff:fee1:c7a4/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:4999 errors:0 dropped:0 overruns:0 frame:0
          TX packets:1917 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:997463 (974.0 KiB)  TX bytes:145674 (142.2 KiB)

[root@localhost home]#

Monday, August 19, 2013

Linux Oracle remotely login with putty + Oracle Home Directory view

login as: root
root@192.168.1.103's password:
Last login: Tue Aug 20 00:04:52 2013 from 192.168.1.105
[root@localhost ~]# /etc/init.d/oracle-xe start
Starting Oracle Net Listener.
Starting Oracle Database 11g Express Edition instance.

[root@localhost ~]# echo $ORACLE_HOME

[root@localhost ~]# echo $ORACLE_HOME

[root@localhost ~]# sqlplus
-bash: sqlplus: command not found
[root@localhost ~]# . /u01/app/oracle/product/11.2.0/xe/bin/oracle_env.sh
[root@localhost ~]# /etc/init.d/oracle-xe start                                                    Oracle Database 11g Express Edition instance is already started

[root@localhost ~]# echo $ORACLE_HOME
/u01/app/oracle/product/11.2.0/xe
[root@localhost ~]# sqlplus

SQL*Plus: Release 11.2.0.2.0 Production on Tue Aug 20 17:52:58 2013

Copyright (c) 1982, 2011, Oracle.  All rights reserved.

Enter user-name: system
Enter password:

Connected to:
Oracle Database 11g Express Edition Release 11.2.0.2.0 - 64bit Production

Linux Display List of Last Shutdown Entires


[root@localhost ~]# last -x| less  


OR
[root@localhost ~]# last -x | grep shutdown | less


shutdown system down  2.6.32-71.el6.x8 Tue Aug 20 00:01 - 00:03  (00:01)
shutdown system down  2.6.32-71.el6.x8 Mon Aug 19 23:22 - 23:24  (00:02)
shutdown system down  2.6.32-71.el6.x8 Mon Aug 19 19:28 - 19:28  (00:00)
shutdown system down  2.6.32-71.el6.x8 Thu Jul 11 23:28 - 16:33 (38+17:05)
shutdown system down  2.6.32-71.el6.x8 Thu Jul 11 00:34 - 16:10  (15:36)
shutdown system down  2.6.32-71.el6.x8 Sat Jun 29 13:04 - 23:53 (11+10:48)
shutdown system down  2.6.32-71.el6.x8 Thu Jun 27 19:50 - 13:01 (1+17:11)
(END)

shift + z + z
for exit the screen

Linux Close file or back


Back From the list    Shift + Z + Z

:wq
or
:x

Linux List Of Reboot of the server Display


[root@localhost ~]# last reboot | less

reboot   system boot  2.6.32-71.el6.x8 Tue Aug 20 00:03 - 00:13  (00:10)
reboot   system boot  2.6.32-71.el6.x8 Mon Aug 19 23:24 - 00:01  (00:37)
reboot   system boot  2.6.32-71.el6.x8 Mon Aug 19 19:28 - 23:22  (03:53)
reboot   system boot  2.6.32-71.el6.x8 Mon Aug 19 16:33 - 19:28  (02:54)
reboot   system boot  2.6.32-71.el6.x8 Thu Jul 11 16:10 - 23:28  (07:18)
reboot   system boot  2.6.32-71.el6.x8 Wed Jul 10 23:53 - 00:34  (00:40)
reboot   system boot  2.6.32-71.el6.x8 Sat Jun 29 13:01 - 13:04  (00:03)
reboot   system boot  2.6.32-71.el6.x8 Fri Jun 28 00:24 - 19:50  (-4:-33)

wtmp begins Fri Jun 28 00:24:05 2013
(END)

Linux Sehedule Shutdown with message for save data of the users

[root@localhost ~]# shutdown +5 "*** Server is going DOWN due to power failure !!! Please save all your work ***"
shutdown +5 "*** Server is going DOWN for  due to power failure ! Please save all your work ***"

Broadcast message from root@localhost.localdomain
        (/dev/pts/0) at 0:08 ...

The system is going down for maintenance in 5 minutes!
*** Server is going DOWN  test! Please save all your work ***