#check user exist or not
select * from dba_users where username=’smavris’;
select * from dba_users where username=’NGREENBERG’;
#check role for testing
select * from dba_role_privs where granted_role=’hremployee’;
#create role for testing
create role hremployee;
grant connect to hremployee;
#grant privs for role
grant select on hr.employees to hremployee;
grant update on hr.employees to hremployee;
#create users to role, on table
grant hremployee to SMAVRIS identified by oracle_4U;
grant hremployee to NGREENBERG identified by oracle_4U;
#check the sound
# description: Tomcat Start Stop Restart
# processname: tomcat
# chkconfig: 234 20 80
case $1 in
ConnectTimeout is the timeout for creating a connection. Let’s say you have an unreliable server and you want to wait only 15 seconds before you tell the user that “something is wrong”.
ReadTimeout is the timeout when you have a connection, you’re blocked on read() and you want to get an exception if the read blocks for more than timeout.
To avoid the HHTP connection session cannot close. We must setup the defined setReadTimeout parameter.
HttpURLConnection urlCon = (HttpURLConnection)url.openConnection();
When You find out something wrong with your server, your website.Maybe your website/server was hacked. Let’s check the source codes, try to find something different. Here is my favorite linux command to explore the reason:
1. List all files with the keyword
find ./ -name “*.php” |xargs grep keyword-hacked
find ./ -name “.htaccess” |xargs grep keyword-hacked
2. List and delete the line containing keyword, save a backup file:
find ./ -name “*.php” |xargs sed -i.bak “/keyword-hacked/d”
find ./ -name “.htaccess” |xargs sed -i.bak “/keyword-hacked/d”
3. Check the result, services on your server,website
Hope this sharing works for you.
I’ve got a problem with data from two database server ( cannot directly select data from tables ). I must do it offline.
The first excel file named: userproduct.xlsx ( contains fields: username, productname ).
The second file named: contentrating ( contains fields: contentname,contentcode,viewer,startview,endview,duration).
Here is my simple solutions: creating two new data tables: [Read more…]
Today I tried to stream out from my laptop to my youtube channel.
Now you can Subscribe / Follow my video channel >>
Here is my script. Just use FFMPEG to create a live stream on youtube:
ffmpeg -re -i "(input-file)" -acodec libmp3lame -ar 44100 -b:a 128k
-pix_fmt yuv420p -profile:v baseline -s 426x240 -bufsize 2048k -vb 400k
-maxrate 800k -deinterlace -vcodec libx264 -preset medium -g 30 -r 30
-f flv "rtmp://a.rtmp.youtube.com/live2/(Stream name/key)"
From camera: [Read more…]
Google support so many total free tools for webmaster. Google said that ” Which is free, we make it better “.
Here some useful links for webmaster:
1. De-Index a website: Index removals ( remove Outdated page removal or entire website )
2. Google Analytics: http://www.google.com/analytics/
3. Google Webmaster Tools: Google Webmaster Tools
4. Google Trends: Trends of searching
Hope it help for you.
Check system reboot or not
Check system hardware
Read log file from latest
tac /var/log/messages |less
Check service on boot
chkconfig --list|grep servicename
Find some wrong setting from configuration files
find ./ -name "*.xml" |xargs grep keyword
Check out which port server listen on: