LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 08-20-2004, 07:51 AM   #1
gubak
Member
 
Registered: Jul 2004
Posts: 332

Rep: Reputation: 30
Make symbolic link or alias


How can I make a symbolic links or aliases which are point to another location?

Last edited by gubak; 10-20-2006 at 07:41 AM.
 
Old 08-20-2004, 07:55 AM   #2
ppuru
Senior Member
 
Registered: Mar 2003
Location: Beautiful BC
Distribution: RedHat & clones, Slackware, SuSE, OpenBSD
Posts: 1,791

Rep: Reputation: 50
ln -s for symbolic link

you can use the alias command to create aliases

e.g.
alias cp="cp -v "
 
Old 08-20-2004, 10:39 AM   #3
guzzi
Member
 
Registered: Jun 2004
Location: Lawrence, KS
Distribution: Slackware
Posts: 301

Rep: Reputation: 35
symlink

This may be of some help.

Lets say you are in your home directory and want to create a file which is really somewhere else. Lets use /etc/inittab as a test.

ln -s give_it_a_name_file /etc/inittab

This will make a file named give_it_a_name_file in your home directory that is really a link to /etc/inittab

Good Luck
 
Old 08-20-2004, 10:54 AM   #4
barisdemiray
Member
 
Registered: Sep 2003
Location: Ankara/Turkey
Distribution: Slackware
Posts: 155

Rep: Reputation: 30
Re: symlink

Quote:
Originally posted by guzzi
This may be of some help.

Lets say you are in your home directory and want to create a file which is really somewhere else. Lets use /etc/inittab as a test.

ln -s give_it_a_name_file /etc/inittab

This will make a file named give_it_a_name_file in your home directory that is really a link to /etc/inittab

Good Luck
No, this will make an error :-)

Code:
[baris@rhinox]$ ln --help
Usage: ln [OPTION]... TARGET [LINK_NAME]
...
correct form is

Code:
ln -s /etc/inittab give_it_a_name_file
 
Old 08-20-2004, 11:10 AM   #5
guzzi
Member
 
Registered: Jun 2004
Location: Lawrence, KS
Distribution: Slackware
Posts: 301

Rep: Reputation: 35
you are right and I am ?

what I should have shown is

ln -s /etc/inittab give_it_a_name

next time I will engage brain before posting.

Thanks for getting me organized.
 
Old 08-20-2004, 01:50 PM   #6
FarAway
LQ Newbie
 
Registered: Jul 2004
Posts: 18

Rep: Reputation: 0
if you wanna make an alias permanently, you can add a line (eg. alias cp="cp -i") into the file ~/.bashrc

hope that helps. ^_^
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
cannot make symbolic link dave`2005 Debian 3 10-08-2005 11:15 AM
Is it possible to make a dir a symbolic link? dr_zayus69 Linux - General 4 03-09-2005 09:48 AM
how do i make DVD symbolic link permanent? RU63 Debian 4 12-28-2004 03:07 PM
How do I make symbolic link with midnight commander? akihandyman Linux - Newbie 1 02-17-2004 08:16 PM
How to make symbolic link? Tommi Linux - General 9 05-07-2003 09:58 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 01:01 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration