Red Hat Bugzilla – Bug 161433
/etc/profile incorrect for ksh as login shell
Last modified: 2014-03-16 22:54:42 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.8) Gecko/20050524 Fedora/1.0.4-4 Firefox/1.0.4
Description of problem:
The following in /etc/profile fails in ksh, because EUID is non-existent.
"/etc/profile: [: argument expected"
if [ $EUID = 0 ]; then
# do something with the path
In FC3, instead of $EUID was used: `id -u`
The package changelog says that
* Sat Apr 16 2005 Bill Nottingham <firstname.lastname@example.org> 2.5.41-1
- get rid of 'id' error messages if there is no /usr (#142707)
But replacing it with a bash-ism is no solution either ...
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1.Give a user ksh as login shell
2.Let him login
Actual Results: /etc/profile: [: argument expected
Expected Results: No errors during login.
*** This bug has been marked as a duplicate of 160731 ***