ManyCodes.com – codes & scripts Get free programming codes and tutorials!

11Jan/120

How to create a symlink in the Linux command console?

 ln -s <destination> <linkname> 

If the desired link filename is the same as the destination's filename, and the current working directory is the desired location for the link, then you only need:

  ln -s <destination> 

A symbolic link (also symlink or soft link) is a special type of file that contains a reference to another file or directory in the form of an absolute or relative path and that affects pathname resolution. Symbolic links were already present by 1978 in mini-computer operating systems from DEC and Data General's RDOS.

Today they are supported by the POSIX operating-system standard, most Unix-like operating systems such as FreeBSD, GNU/Linux, and Mac OS X, and also Windows operating systems such as Windows Vista, Windows 7 and to some degree in Windows 2000 and Windows XP.Symbolic links operate transparently for most operations: programs which read or write to files named by a symbolic link will behave as if operating directly on the target file. However, programs that need to handle symbolic links specially (e.g., backup utilities) may identify and manipulate them directly.

6Aug/090

How to Run as Administrator in Vista Command Line?

Recently I wanted to do some actions in Windows Vista command line prompt but with elevated access as an Administrator. You may need this access to do actions like creating symbolic links etc.

So, how to run as administrator in Vista command line?

The easiest way is to use the type cmd in the Vista Start Run box and use the keyboard shortcut Ctrl + Shift + Enter instead of just pressing Enter. This will open the Command Prompt in Administrator mode.

cmd in Vista

You can also right click cmd.exe and click Run as Administrator.

cmd as administrator in Vista

Command Prompt with Administrator access in Windows Vista.

Run Vista Command Prompt as Adminstrator

On the other hand, you can also activate Administrator account in Vista, so that you can login from welcome screen.