.profile problem using set -o vi


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers .profile problem using set -o vi
# 8  
Old 12-22-2006
Actually he wanted the info added to your .profile not on the command line (or at least that's how I read it since it's not working in the script but it is on the command line; you do the troubleshooting from where it doesn't seem to be working Smilie ).

The only time I've experienced a problem is if something earlier doesn't run and .profile bails but I can't be sure that wasn't a Red Hat feature (so many systems Smilie ). Are the other items working? The PATH modified and NDMAPICFG set? If you move the set command to the top of .profile, does it work?

Carl

Edit: Oh, and if you source your .profile does it work?

Code:
$ . ./.profile

# 9  
Old 12-22-2006
Hay Carl, I think your on to something....
yes - the source did work.
yes - my path and ndmapicfg and "stty erase" does work

no - moving "set -o vi" to the top (above stty erase ^H) doesn't work
no - placing those command in the .profile did not help.

Grrr... this seems to easy to not work.
# 10  
Old 12-22-2006
Quote:
Originally Posted by jimmyc
no - placing those command in the .profile did not help.
jimmy, you need to modify your .profile file as I indicated. Then you need to logon. Then you need to post the output from those commands. No, those lines will not solve anything. But if you would post the output they produce when you logon, we can probably figure out what is happening.
# 11  
Old 12-28-2006
Here's the output from the commands in the .profile ....
Please see note at bottom.

Last login: Thu Dec 28 08:07:29 from 192.168.0.214
Sun Microsystems Inc. SunOS 5.10 Generic January 2005
UID PID PPID C STIME TTY TIME CMD
jcusic 7813 7807 0 14:17:29 pts/2 0:00 ps -f
jcusic 7807 7804 1 14:17:24 pts/2 0:00 -ksh
Current option settings
allexport off
bgnice on
emacs off
errexit off
gmacs off
ignoreeof off
interactive on
keyword off
markdirs off
monitor on
noexec off
noclobber off
noglob off
nolog off
notify off
nounset off
privileged off
restricted off
trackall off
verbose off
vi on
viraw off
xtrace off
Current option settings
allexport off
bgnice on
emacs off
errexit off
gmacs off
ignoreeof off
interactive on
keyword off
markdirs off
monitor on
noexec off
noclobber off
noglob off
nolog off
notify off
nounset off
privileged off
restricted off
trackall off
verbose off
vi on
viraw off
xtrace off
$ -fs
set -o vi
set -o
ksh: -fs: not found
$ set -o vi
$ set -o
Current option settings
allexport off
bgnice on
emacs off
errexit off
gmacs off
ignoreeof off
interactive on
keyword off
markdirs off
monitor on
noexec off
noclobber off
noglob off
nolog off
notify off
nounset off
privileged off
restricted off
trackall off
verbose off
vi on
viraw off
xtrace off

Grrr... logon is a generic term which I didn't stop to think about. When I telnet in... It works at expected! But I don't use telnet. I use Hummingbird to make a xwindows connection. Here's the command used to make that connection.
/usr/openwin/bin/xterm -bg black -fg yellow -sb -title SUN01--172.16.25.12-- -geo 110x30
When I login using this method I don't get any output from those commands and the set -o vi doesn't work till entered from the command line.
# 12  
Old 12-28-2006
The xterm man page says:

Quote:
-ls This option indicates that the shell that is started in the xterm window be a login shell (i.e. the first character of argv[0] will be a dash, indicating to the shell that it should read the user's .login or .profile).
# 13  
Old 12-29-2006
Thanks Perderabo !!! That did it. No wonder I couldn't figure it out. I was looking in the wrong place all the time... New xterm line is...
/usr/openwin/bin/xterm -ls -bg black -fg yellow -sb -title SUN01--172.16.25.12-- -geo 110x30
 
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

"ksh: XYZ: parameter not set" in .profile

Hi, A very basic query. I am working on two different UNIX servers and I see different behaviours for my user id. This has to be a setting in the .profile, but I can't seem to find where :confused: So, in one server if I type echo $XYZDD (a random variable), I get a blank line with no... (2 Replies)
Discussion started by: ALDonP
2 Replies

2. Shell Programming and Scripting

How to set up newgrp on .profile?

Hello all, I am having an issue setting up an environment on .profile. I want to set up my .profile in that way that everytime I login to the host, it should automatically set up my group. I tried the folllowing but it doesn't work. It is on the solaris OS. HOSTNAME=$(hostname) if ] || ]... (14 Replies)
Discussion started by: Pateltiger
14 Replies

3. AIX

How to make LOGNAME writeable? It is set as READONLY in .profile

LOGNAME variable is set as READONLY in .profile. I want to make it WRITEABLE so that I can modify the LOGNAME values programatically/throush shell programs. Thanks, Guru (1 Reply)
Discussion started by: gurubbc
1 Replies

4. Solaris

How do i permanently set bash profile??

Hi all, I don't want to enter below command on solaris every time. How do i permanently set this command on Solaris. I know that this operation is a piece of cake on redhat because there is a /etc/rc.local file on it. But Solaris ???? bash-3.00#export PS1="\e (2 Replies)
Discussion started by: getrue
2 Replies

5. Solaris

profile problem

for some reason my profile doesnt seem to be loading. here is some info $SHELL /sbin/sh $HOME / (yup, im running at root, its a VM and im using it to learn) created /.profile added something simple to test, PS1="test" logout and back in, open a terminal... prompt is still # ... (2 Replies)
Discussion started by: jrich523
2 Replies

6. Shell Programming and Scripting

problem with .profile

I am trying to execute my .profile which has the path to oracle home. But when I execute it with the below command it says nothing and when I try to echo the ORACLE_HOME I am still in my home directory itself which means it didn't get executed. Please help how to make sure that .profile is... (6 Replies)
Discussion started by: dsravan
6 Replies

7. UNIX for Dummies Questions & Answers

set background/foreground color in .profile

I am using a telnet session (VT100) and need to modify my .profile so that it will set the color of the telnet session. I am not using Xterm (ie: can't use .Xdefaults). I am able to change the colors via menu's but need to preset in .profile. Is this possible??? Can't find anything at all on how... (3 Replies)
Discussion started by: dvella
3 Replies

8. UNIX for Dummies Questions & Answers

problem with .profile

Hi, i am changing something in .profile file and then esc :wq!. when i do the cat i can see the changes. but to bring the .profile in memory i have to do . .profile.but it says error while doing that is . .profile ksh: .profile: not found. can any body help thanks in advance sam71 (7 Replies)
Discussion started by: sam71
7 Replies

9. UNIX for Dummies Questions & Answers

ssh2: .profile not set correctly

When logging into solaris box through ssh, my profile does not get set correctly and I'm presented with the default ksh prompt "$". When logging in through telnet, everything is set correctly. Is there a special profile that sshd runs? ssh2: F-Secure SSH 2.4.0 (build 15) on sparc-sun-solaris2.8 (0 Replies)
Discussion started by: dangral
0 Replies

10. UNIX for Dummies Questions & Answers

Problem with .profile

I wanted to add /home/oracle/sql to my path so that from which ever directory i connect to sqlplus i should be able to source the .sql files sitting in /home/oracle/sql. Also, this is what i tried but it doenst work # Set up the search paths: export ... (2 Replies)
Discussion started by: jigarlakhani
2 Replies
Login or Register to Ask a Question