This is a discussion on using aliases with ifconfig--- HOWTO within the Slackware Linux Support forums, part of the Unix Operating Systems category; --> Yesterday RayzrShrp asked if there was a way to alias the return from ifconfig. I replied that the best ...
| |||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| Yesterday RayzrShrp asked if there was a way to alias the return from ifconfig. I replied that the best way would be to hack ifconfig to read an alias file. So today I spent some time and hacked net-tools, where ifconfig comes from, to read an alias file in /etc. You can get it here: http://home.comcast.net/~aardvark2/hacked-tools.html You will need to compile from source to get it to work. ../configure make su make install { for those that are just joining us } And I suggest that you also download the unhacked version and run diff on them. This will show what I did and that I didn't put anything malicious in the code. Remember boys and girls always CYA. Make sure you read the README-ALIAS-HACK file for instructions. One more quick note. You only get the alias if ifconfig is called with no arguments. If called with arguments you get the default behavior. If there is no alias file you get the default behavior. If there is no alias in the alias file you get the default behavior. JM |