Transfer files and folders between two SSH server using SCP

Linux No Comments »

To transfer files and folders between two SSH server follow the instructions bellow:

log in to your new SSH server

to get the files and folders from old SSH server run the following command:

scp USER_NAME@oldserver.com:/path_in_old_server/ /path_in_new_server/

you will be prompted to enter password for old server, note that if you are using SSH keys this won’t work

URL encoding codes for special characters

xHTML No Comments »
Character Code
Points
(Hex)
HTML
Dollar (”$”)
Ampersand (”&”)
Plus (”+”)
Comma (”,”)
Forward slash/Virgule (”/”)
Colon (”:”)
Semi-colon (”;”)
Equals (”=”)
Question mark (”?”)
‘At’ symbol (”@”)
24
26
2B
2C
2F
3A
3B
3D
3F
40
put “%” in the beginning. for examplefor “&” use “%26″ so in a URL

like http://www.web.com/title&des.ext

the safe URL to use will be ../title%26des.ext

Read the rest of this entry »

How to use/install rar/unrar (winrar) in CentOs

Linux No Comments »

After trying to install rar/unrar in my dedicated Linux box(CentOS 4) I encountered different kind of problems and after googleing around found different solution, none of them applicable to me or either I didn’t want to screw things around much

first I tried yum install rar, which didn’t work due to using wrong repo (didn’t bother trying to change the repo)

tried apt-get install rar, didn’t work neither due to not having apt-get

now the solution,

just download the latest RAR Linux version from rarlab website: http://www.rarlab.com/download.htm

wget http://www.rarlab.com/rar/rarlinux-3.7.1.tar.gz

extract the archive using the following command:

gzip -dc rarlinux-3.7.1.tar.gz | tar xf -

go into the extracted directory, cd rar

now as you might have encountered you may get the error of not having glibc_2.4, here is the work around, do the following Read the rest of this entry »

How to rename multiple files

Linux No Comments »

for example you have set of files with some perfix in their name and you want to get rid of it or change it to something else

here is the command you can use: Read the rest of this entry »

How to copy an directory with files

Linux No Comments »

Here is the command to copy an entire directory with files inside it to a new directory

cp -R directory_name_you_want_to_copy/ new_directory/

how to extract tar.bz2 archives

Linux No Comments »

First, you need the bzip2 package. Get it from your favourite FTP site if you haven’t already got one. Next, to view the contents, simply do this:

$ bzip2 -cd files.tar.bz2 | tar tvf -

To extract, do this instead:

$ bzip2 -cd files.tar.bz2 | tar xvf -

Of course, you can also use something like: Read the rest of this entry »

usefull zip, unzip command options / syntax

Linux No Comments »

How to unzip a directory:
unzip directory_name

How to zip a directory in current location:
zip -9 -r zip_file_name directory_name

How to zip and encrypt (give password to zip file):
zip -9 -r -e zip_file_name directory_name

Examples scenarios: Read the rest of this entry »

Find and replace in MySQL database using phpMyAdmin or just PHP

MySQL, PHP No Comments »

You can find and replace anything in a MySQL database by using a simple command in phpMyAdmin or in a php file

To do this is phpMyAdmin simply select your databae first from left pane and then in right pane at the top select SQL and run the following commad: Read the rest of this entry »

Mass Unzip in shell/SSH

Linux No Comments »

Ever wanted to unzip multiple files in the same directory at once? have you tried “unzip *.zip” just like me as a DOS person? well you can do that in shell under Linux even if archive files are password protected, however they all should have the same password and be in the same directory for the following syntax to work

By the way you can probably use the same idea to run other commands than “unzip”, “tar” for example.

here is the syntax: Read the rest of this entry »

SEO Rules

SEO No Comments »

Having a successful website these days depends on how easy you can be found on search engines

Now how can you improve your website so can be found easily, here are the simple yet important rules you should follow to achieve thah

To do’s:

1. Have a related Title name to your page content.

2. Use related keywords to your page content.

3. Make use of your keywords in content, for example if you have “Madonna” as one of your keywords, you should have a paragraph related to Madonna with actually mentioning the keywords itself “Madonna” in your page.

4. Make use of “Alt” tags and always give a discreption to your images, no matter what they are. Read the rest of this entry »

© 2005-2007 OZPERSIA.NET
Entries RSS Comments RSS Login