Visit Our UNIX and Linux User Community

Can't find where alias is set

Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers Can't find where alias is set
# 1  
Old 01-18-2012
Can't find where alias is set

I have an alias set on linux:

progs -> /home/user01/

the location of prog is changes to /home/user01/new/

so I need to modify alias, except I can not find where it is set. It is not in .bashrc or .profile, it is visible by "alias" command.

Sorry if it is trivial.
# 2  
Old 01-18-2012
Look in /etc/profile.
This User Gave Thanks to Corona688 For This Post:
# 3  
Old 01-18-2012
Thanks for reply but it is not there as well.

Is there is any way to modify it by command line?
# 4  
Old 01-18-2012
sometimes aliases are defined in ~/.bash_aliases or ~/.bash_login

Anyway you may set an alias by command line with:
alias <alias>='<command>'

but it's valid only in the current interactive shell.

see also:

see ya
This User Gave Thanks to frappa For This Post:
# 5  
Old 01-18-2012
yes, I can set alias for the current shell like that.

And I don't have ~/.bash_aliases

Still wondering where the alias might be

---------- Post updated at 04:08 PM ---------- Previous update was at 03:11 PM ----------

ok solved

alias was in /etc/bash.bashrc (wtf??? Smilie)

Thanks for suggestions though

Previous Thread | Next Thread
Test Your Knowledge in Computers #802
Difficulty: Medium
The CSS @font-face rule is not supported across the main browsers, Internet Explorer, Firefox, Opera, Chrome, and Safari.
True or False?

9 More Discussions You Might Find Interesting

1. Solaris

How to set a global alias in UNIX Solaris?

Defined a user alias in unix. Not able to use that alias in a ksh scritp. I dont want to change/source in the script to set the value. Need to set the user alias as a gloabal alias to use it in a new ksh shell window. Can you please help on this? (3 Replies)
Discussion started by: rbalaj16
3 Replies

2. Red Hat

alias ip problem,i canīt find out solution

hi, we have eth1; in the beginning it was proposed to create from eth1, eth1.2500 and eth1.240. It did not worked cause vlan 1.2500 was not tagged in the switch. so they decided to leave eth1 like a physical interface with eth1.2500 config (removel vlan tag) and create eth1.240 but it did... (0 Replies)
Discussion started by: pabloli150
0 Replies

3. UNIX for Dummies Questions & Answers

Create alias files (not alias commands)

If one: $ find -name 'some expression' -type f > newfile and then subsequently wants to create an alias file from each pathname the find command retrieved and the > placed within 'newfile', how would one do this? Ideally, the newly created alias files would all be in one directory. I am... (3 Replies)
Discussion started by: Alexander4444
3 Replies

4. UNIX for Dummies Questions & Answers

Find command to exclude directories and setup alias or script?

Hi, Firstly - sorry for the duplicate my other post looked like i was posting a how to for people. But i am wanting some help :P I want to search from / to find files and exclude my mounted ntfs drives. I have found this thread (Which I can't post the URL to until i have 5 posts) it's... (4 Replies)
Discussion started by: mightymouse2045
4 Replies

5. Programming

SQL: find if a set od dates falls in another set of dates

Don't know if it is important: Debian Linux / MySQL 5.1 I have a table: media_id int(8) group_id int(8) type_id int(8) expiration date start date cust_id int(8) num_runs int(8) preferred_time int(8) edit_date timestamp ON UPDATE CURRENT_TIMESTAMP id... (0 Replies)
Discussion started by: vertical98
0 Replies

6. UNIX for Dummies Questions & Answers

PATH set but I can't find where!!!!

Hi, Can anybody help with this? When I log into my user account on my box via ssh and then instantly perform an env command I see that my path has been set as follows: PATH=/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin My user account uses the ksh shell. In my home directory there is no... (7 Replies)
Discussion started by: Donkey25
7 Replies

7. Shell Programming and Scripting

How to set alias and ps1 in a script

I am sure this is a newbie question, but I have searched everywhere and cannot find an answer. My situation is that due security constraints, I cannot modify my .profile file. I have a set of fairly common things that would normally go in the .profile, like setting up alias assignments and... (2 Replies)
Discussion started by: SpringRubber
2 Replies

8. UNIX for Dummies Questions & Answers

Help with find command on a shortcut directory(Alias)???

Hi All, I am trying to find some files on a directory( /usr/users/xyz/log) which is an alias to another directory(/spare/log). My find works fine on /spare/log but it doesnt return anything when i use it on /usr/users/xyz/log. Any Ideas on how to proceed. Thanks in advance. Swamy (2 Replies)
Discussion started by: swamy455
2 Replies

9. UNIX for Dummies Questions & Answers

alias for find

I've tried to define an alias for the find cmd. I want a find -name and send the error messages to /dev/null. I entered the alias as followed: # alias myfind 'find $1 -name $2 2>/dev/null' But it didn't work. Any idea what's wrong with that? (2 Replies)
Discussion started by: sTorm
2 Replies

Featured Tech Videos