eMarcel.com

Oracle Database, Fusion Middleware, Linux

Shell Scripts

Shell script: Copy files from source to target directory

Simple shell script to search and copy files from one folder to another. Pretty useful if there is a need to copy/move files from one folder to another (e.g., Dropbox) in case that running program cannot be configured to write output files to multiple locations. The existing files in the destination folder are skipped. However bear in mind that this […]

,

Top Memory and CPU consumers UNIX, LINUX

Linux OS #current user: $ ps u USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND user 16038 0.0 0.1 4852 784 pts/0 Ss+ Oct28 0:00 /bin/bash #to display the top CPU consumer $ ps aux | sort -nk +3 | tail -1 #to display the top memory consumer $ ps aux | […]

, , ,

Oracle database startup shutdown script

Automate Oracle Database startup shutdown script orarun – script automates database start, stop, status query tasks, also allows user to manage isqlplus console and em database control Usage: orarun {start|stop|status|isqlstart|isqlstop|emstart|emstop} orarun start|stop|status  – starts/stops database, query for database status orarun isqlstart/isqlstop – starts/stops isqlplus console orarun emstart/emstop  – starts/stops enterprise manager database control Requirements: configured […]

, , , , ,

Convert Videos AVI to MPG

Convert Videos AVI to MPG #!/bin/sh ######################################################################## #avi2mpgconv.sh – video converter avi2mpg #Script by: [email protected] (eMarcel.com) (c)2009 GPL #Purpose: To convert digital camera’s avi videos to mpg format, #it allows you to convert avi videos to mpg format which is much smaller #Howto use: $sh avi2mpgconv.sh <videos’ directory path> #suitable for Ubuntu (easy to modify […]

, , ,

Show number of CPUs UNIX

#!/bin/bash #This script will show you number and name of CPUs in UNIX environment. num=`/usr/sbin/psrinfo | wc -l ` tipo=`/usr/sbin/prtconf -pvPD | egrep -e “device_type.*cpu|name” | sed -n “/device_type/{n;p;}” | awk -F’ ‘{ print $2 }’ | sed -e “s/SUNW,//” | head -1` if [ “$tipo” = “cpu” ] then tipo=`/usr/sbin/prtconf -pvPD | egrep -e […]

Show number of CPUs

#!/bin/bash #This script will show you amount and name of CPUs including vmware cpu’s if they exist. name=”$( cat /proc/cpuinfo | awk -F: ‘ /vendor_id/ { vendor=$2 } /model name/ { model=$2 } /cpu MHz/ { if ( model ~ “Hz” ) {speed=””} else { speed=$2 “MHz” }; print vendor, model, speed; } ‘ | […]

Convert resize photos images – Konwertuj zdjęcia

#!/bin/sh ######################################################################## #sizeconv.sh – size converter #Script by: [email protected] ( [email protected] ) (c)2008 GPL #Purpose: To convert jpg images, #it allows you to convert big pictures from you digital camera to small version #Howto use: $sh sizeconv.sh <pictures’ directory path> #suitable for Ubuntu (easy to modify for other distros – imagemagick installation part) #it’s just […]

, ,

Random password generator – Losowe generowanie haseł

Random Password generator – let’s generate the password from within the urandom mess….

Show me IP: Linux, FeeBSD, SunOS

Shell script: read and show ip address – suitable with Linux, FreeBSD and SunOS

Compress Oracle Archive logs 10 in 1 sequence

This script will archive and compress Oracle Database Archive Logs into one package of 10 log files.

Previous Posts

By continuing to use the site, you agree to the use of cookies. more information

The cookie settings on this website are set to "allow cookies" to give you the best browsing experience possible. If you continue to use this website without changing your cookie settings or you click "Accept" below then you are consenting to this.

Close