Tuesday, February 13, 2018

getting hardware information on Linux

cat /sys/devices/virtual/dmi/id/product_name

/sys/devices/virtual/dmi/id/sys_vendor

sudo lshw
sudo lshw -short

cat /proc/cpuinfo
cat /proc/meminfo


Friday, February 9, 2018

connecting pdb user to oracle 12c gives error ORA-01033

If you connect to a user in a PDB and u get error ORA-01033

and following query returns MOUNTED

SELECT name, open_mode FROM v$pdbs;

then we need to open it in read write mode and save state so that it would survive a shutdown.



sqlplus / as sysdba

SELECT name, open_mode FROM v$pdbs;


alter pluggable database PDBORCL open read write;


alter pluggable database all save state;



Oracle 12c: ORA-65096: invalid common user or role name

SQL> create user rakesh identified by rakesh;
create user rakesh identified by rakesh
            *
ERROR at line 1:
ORA-65096: invalid common user or role name


Fix;

SQL> show con_name

CON_NAME
------------------------------
CDB$ROOT
SQL> select PDB from V$services;

PDB
------------------------------
PDBORCL
CDB$ROOT
CDB$ROOT
CDB$ROOT
CDB$ROOT

SQL> alter session set container=PDBORCL;

Session altered.

SQL> show con_name

CON_NAME
------------------------------
PDBORCL
SQL> create user rakesh identified by rakesh;
create user rakesh identified by rakesh
                                 *
ERROR at line 1:
ORA-01109: database not open


SQL> alter database open;

Database altered.

SQL> create user rakesh identified by rakesh;

User created.


SQL> GRANT CONNECT, RESOURCE, DBA TO rakesh;

Grant succeeded.

SQL>

Saturday, January 20, 2018

Arch Linux - Installing packages from AUR repository

goto https://aur.archlinux.org/

goto Packages tab

select your package to install

copy the git clone url ( copy link location)


Now
open terminal window
cd to Downloads folder

for eg to install google chrome

git clone https://aur.archlinux.org/google-chrome.git


now cd to the directory created

cd google-chrome

makepkg -s
(makes package from the git source files)

(All above commands to be run as regular user)

sudo pacman -U   google-chrome-63.0.3239.132-1-x86_64.pkg.tar.xz
(google-chrome-63.0.3239.132-1-x86_64.pkg.tar.xz was created by the prev command)


thats all. :)

Saturday, January 13, 2018

getting ins_ctx.mk error - Oracle 11g R2 install on centos 7

The information below solved the problem:

 

Source :

https://www.davemalpass.com/oracle-database-11g-install-on-centos-7/

 

Oracle Database 11g install on Centos 7

Problem encountered when installing Oracle 11g on Centos 7

Google suggested this was a fairly common problem with machines with a newer GLIBC. Most of the suggested solutions didn’t work for me (writing a glib memcpy shim etc). Instead I was able to statically link this executable against the glibc archive which didn’t have the problem with the missing memcpy@GLIBC reference.
yum install glibc-static.x86_64
yum install glibc-static.i686
vi /u01/app/oracle/product/11.2.0/dbhome_2/ctx/lib/ins_ctx.mk
ctxhx: $(CTXHXOBJ)
-static $(LINK_CTXHX) $(CTXHXOBJ) $(INSO_LINK) /usr/lib64/stdc.a
I additionally had to patch the the ins_emagent.mk to link to the libnnz11 library:
vi /u01/app/oracle/product/11.2.0/dbhome_2/sysman/lib/ins_emagent.mk
Search for the line
$(MK_EMAGENT_NMECTL)
Change it to:
$(MK_EMAGENT_NMECTL) -lnnz11
Then press the Retry button and it should install correctly!

——
ALTER SYSTEM SET PROCESSES=500 SCOPE=SPFILE;
ALTER SYSTEM SET OPEN_CURSORS=500 SCOPE=SPFILE;

Monday, December 11, 2017

multihop socks proxy over ssh

https://superuser.com/questions/332850/ssh-as-socks-proxy-through-multiple-hosts

Followers

About Me

Torrance, CA, United States