Sponsored Content
Top Forums UNIX for Dummies Questions & Answers Can't find where alias is set Post 302591108 by analyst on Wednesday 18th of January 2012 02:17:46 PM
Old 01-18-2012
Can't find where alias is set

I have an alias set on linux:

progs -> /home/user01/prog1.pl

the location of prog is changes to /home/user01/new/prog1.pl

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.
 

9 More Discussions You Might Find Interesting

1. 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

2. 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

3. 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

4. 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

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

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

7. 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

8. 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

9. 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
aliascheck(1)							Mail Avenger 0.8.3						     aliascheck(1)

NAME
aliascheck - check for existence of mail alias SYNOPSIS
aliascheck [--nopwd] name [alias-file] aliascheck --map [--case] name map-file aliascheck --qmail [--nopwd] name [alias-user] DESCRIPTION
aliascheck checks whether name is a valid email alias or a user in the password file. It converts name to lower-case before performing any of the checks. If the alias or user exists, aliascheck exits with status 0 and outputs what the address resolves to. If the alias does not exist, aliascheck exits with status 1. If aliascheck cannot determine the validity of name because of some system error, it exits with status 2. aliascheck can run in three different modes--sendmail alias mode (the default), sendmail map mode, and qmail mode. In sendmail alias mode the second argument, alias-file, is the name of the sendmail alias file, typically /etc/mail/aliases.db. If no second argument is supplied, aliascheck first checks for the existence of /etc/mail/aliases.db, then for the existence of /etc/aliases.db, then finally exits with status 2 if neither file exists. When an alias is found, aliascheck outputs the value of that alias in the alias database. When aliascheck is invoked with --map, it looks up name in map-file, which should be a database created with sendmail's makemap(8) utility. Note that maps have a slightly different and incompatible format from that of alias files. Use the --case argument to prevent name from being folded to lower-case before it is looked up in the database. Note that --map implies the --nopwd option. When aliascheck is given the argument --qmail, it runs in qmail mode. In this case, the second argument, alias-user, specifies the user under which qmail processes mail aliases. aliascheck will check this user's home directory for files named .qmail-XXX for various appropriate suffixes XXX. On success, it outputs the full pathname of the appropriate file. If aliascheck cannot find an alias, it also checks the password file, and exits 0 if it can find name there. If name is found, aliascheck also outputs name (in lower-case) to standard output before exiting. (This is useful for Mail Avenger, because asmtpd does not recognize users with invalid shells or UID 0, while MTAs typically do.) To suppress password file checking, supply the --nopwd argument to aliascheck. EXAMPLES
If you are using Mail Avenger in conjunction with a sendmail installation, you might want to put the following code in your /etc/avenger/unknown file to reject mail for unknown users who do not show up in the alias file. aliascheck "$RECIPIENT_LOCAL" /etc/mail/aliases.db > /dev/null case "$?" in 0) # Fall through to default checks ;; 1) reject unknown user ;; *) # Probably safest to do nothing, but could also # defer the mail with the following command: # #defer Temporary error processing alias file ;; esac If you have qmail instead of sendmail, assuming the qmail alias user is called "alias", you would change the first line in the previous example to: aliascheck --qmail "$RECIPIENT_LOCAL" alias > /dev/null FILES
/etc/avenger/unknown Mail Avenger rules for local email addresses that do not correspond to local users, or correspond to local users without valid shells, or local users with uid 0 (i.e., root). Note the location may be different if you set EtcDir in your asmtpd.conf file. /etc/mail/aliases.db /etc/aliases.db Default locations of sendmail alias file /etc/mail/virtusertable.db Default location of the sendmail virtual user table map, when this feature is in use. ~alias/.qmail-* Default locations of qmail alias files /etc/password System password file. (Note, however, that aliascheck uses the getpwnam function, and will thus be compatible with schemes such as NIS that do not keep all users in the local password file.) SEE ALSO
avenger(1), asmtpd.conf(5), makemap(8), The Mail Avenger home page: <http://www.mailavenger.org/>. BUGS
aliascheck doesn't necessarily know how to parse the particular database format your sendmail installation uses for aliases. Make sure you test it before using it in an avenger script. In some sendmail installations, the alias database is not world readable, which can obviously prevent aliascheck from working properly if run under the wrong user identity (such as the AvengerUser). It is quite possible for aliascheck to return a system error (exit code 2), particularly if you run it while you are rebuilding a large alias database. (aliascheck checks for the existence of special key "@" in the database.) Make sure you differentiate between error code 1 (no user) and error code 2 (system error). aliascheck may not do the right thing if you installed qmail with conf-break set to a character other than "-". Remember that aliascheck does not read your qmail users/assign or users/cdb files--it only checks for .qmail files in the alias user's home directory. AUTHOR
David Mazieres Mail Avenger 0.8.3 2012-04-05 aliascheck(1)
All times are GMT -4. The time now is 09:36 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy