consistency between ssh and shell window environments?

Status
Not open for further replies.

DaPlumber

Patron
Joined
May 21, 2014
Messages
246
It would seem that the environments are a little different between ssh root@freenas and the shell window in the GUI. I'm guessing the shell window is pulling its environment from the DB as well as/instead of the usual profile/etc suspects?

Is there a simple way to make the ssh environment consistent with the shell window without having to reverse engineer the shell window environment?:rolleyes: It's not just PS1 either.;)
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
10,996
You are not talking about the fact that the GUI shell uses bash and the SSH uses csh, are you? I suspect you want all the environment variables?

So if it is the shell differences you are talking about, in the SSH window just type bash, or int he shell window type csh, depending on what you want. I like tcsh myself.
 

DaPlumber

Patron
Joined
May 21, 2014
Messages
246
You are not talking about the fact that the GUI shell uses bash and the SSH uses csh, are you? I suspect you want all the environment variables?

So if it is the shell differences you are talking about, in the SSH window just type bash, or int he shell window type csh, depending on what you want. I like tcsh myself.


No, my root user $SHELL is already set to bash, I have to deal with enough shell schizophrenia in my life without it on the same system. I was talking about the environment variables, aliases, etc.

Full disclosure: I "grew up" with Bourne, C, and Korn (if I was lucky). You darn kids don't know how lucky you got it these days... mutter... lawn...:rolleyes::p
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
10,996
I grew up with pure machine code. My avatar does not lie. Then using tools like Microsoft Macro Assembler Version 1 was such a huge boost! Imagine writing something like this all day and it produces a result
Code:
mov ax,cx
xor ah,al
int 21


The first big challenge is to write a tic-tac-toe program against the computer, and the computer never looses. After that it's something more advanced but a simple game makes you think about how to program, and in a low level language it's a lot of work.

Where I work right now, in the same building, was the first computer bug and actually where the term computer bug was coined. No shit, I've seen it in person, the moth taped into the user notes book. It use to be on display but it has since been moved, but I don't know where. A moth that got into a relay. That was of course before my time. Not sure I have the smarts to build a computer out of relays.
 

gpsguy

Active Member
Joined
Jan 22, 2012
Messages
4,472
I believe the moth now resides in the Smithsonian Museum.


Sent from my phone
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
10,996
It may, that's only just up the road from where I live.
 

DaPlumber

Patron
Joined
May 21, 2014
Messages
246
I grew up with pure machine code. My avatar does not lie. Then using tools like Microsoft Macro Assembler Version 1 was such a huge boost! Imagine writing something like this all day and it produces a result
Code:
mov ax,cx
xor ah,al
int 21


The first big challenge is to write a tic-tac-toe program against the computer, and the computer never looses. After that it's something more advanced but a simple game makes you think about how to program, and in a low level language it's a lot of work.

Where I work right now, in the same building, was the first computer bug and actually where the term computer bug was coined. No shit, I've seen it in person, the moth taped into the user notes book. It use to be on display but it has since been moved, but I don't know where. A moth that got into a relay. That was of course before my time. Not sure I have the smarts to build a computer out of relays.

Admiral Grace Hopper has a lot to answer for... COBOL (ugh) included! ;-)

That's assembler not machine code. ;-) Real Programmers can latch and boot the box by toggling the front panel. ;-)

Shift to the Left,
Shift to the Right,
Pop On, Pop Off,
Byte, Byte, Byte!
 

solarisguy

Guru
Joined
Apr 4, 2014
Messages
1,125
Front panel is easy ;) Just toggle the switches and press load. Then toggle the switches and press load...
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
10,996
We had a computer in which to bootstrap it you pressed a button and a stepper motor clicked right along going through a large matrix of diodes and that would setup booting from a 8 Megabyte drum memory. The RAM was ferrite cores, and reading the bit was a destructive operation. Oh the good ole' days. And when we needed to make a change, punched cards baby!
 

DaPlumber

Patron
Joined
May 21, 2014
Messages
246
There is family heirloom that I will eventually inherit that is a Burroughs board of one of the last generations of ferrite core memory. It's almost microscopic and was "sewn" by hand by ladies in South America rather than manufactured. Punch cards do make good bookmarks. Ever drop a deck? That wasn't numbered? :mad: Anyone ever make a lace card? Deliberately? ;) Anyone else still got some 1600BPI reel with code they wrote on it? Ever make Xmas decorations out of write rings? ;) Word. :D

Wrenching this back on topic from the nostalgia jag:

Where does the FreeNAS GUI set the Shell window environment from?
 

DaPlumber

Patron
Joined
May 21, 2014
Messages
246
Let's make it even simpler. Why the console is C and GUI Shell window is en_US.UTF-8 ?


I think this is all part of the same problem. Ssh and Console all use "standard" login system and environment settings as far as I can tell. GUI Shell Window seems to be the exception.
 

Whattteva

Wizard
Joined
Mar 5, 2013
Messages
1,824
I never even realized that the GUI shell window has different environment. I guess it's cause I never really use it cause it conflicts with my browser settings (I run a vimperator), so it's really annoying to have to keep toggling ignore keys to type into the shell.
Additionally, from my experience in the past of using it (around 8.2 I think), it (the UI) was a bit buggy and I just stopped using it entirely since then.
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
10,996
Going off topic again... And I recall the days of 110 baud over the phone handset.

On topic... It would be nice if the GUI shell were the same as the SSH environment, or at least I use the SSH shell a whole lot more so I'm use to it.
 

Whattteva

Wizard
Joined
Mar 5, 2013
Messages
1,824
Going off topic again... And I recall the days of 110 baud over the phone handset.

On topic... It would be nice if the GUI shell were the same as the SSH environment, or at least I use the SSH shell a whole lot more so I'm use to it.
That's another reason I never use the GUI shell. It has that overhead of loading the rest of the GUI when I really only need the shell. Minor convenience if you're on the local network, but a lot more annoying when you're on a slow WiFi. Plus mosh is just a lot more pleasant to use on dodgy connections, too.
 

DaPlumber

Patron
Joined
May 21, 2014
Messages
246
That's another reason I never use the GUI shell. It has that overhead of loading the rest of the GUI when I really only need the shell. Minor convenience if you're on the local network, but a lot more annoying when you're on a slow WiFi. Plus mosh is just a lot more pleasant to use on dodgy connections, too.


Well it kinda depends on if I happen to have the GUI open anyway...:rolleyes:
 

Whattteva

Wizard
Joined
Mar 5, 2013
Messages
1,824
Well it kinda depends on if I happen to have the GUI open anyway...:rolleyes:
I suppose you have a point there, but I'm curious as to other people's use cases. I rarely ever actually log in to the FreeNAS shell.
99% of the time, I only login to my jail and I do pretty much everything I need there.
The other 1% of the time is when I actually need to do some admin tasks on the actual host system, but those times are few and far between. How do you people use it?
 

SmallGuy

Guru
Joined
Jun 7, 2013
Messages
560
I suppose you have a point there, but I'm curious as to other people's use cases. I rarely ever actually log in to the FreeNAS shell.
99% of the time, I only login to my jail and I do pretty much everything I need there.
The other 1% of the time is when I actually need to do some admin tasks on the actual host system, but those times are few and far between. How do you people use it?
+1
I use Putty and Pageant, and most of the time tcsh environment. Take me about 10 seconds to login the first time, the time necessary to enter the key. An other advantage is you can open several sessions at the same time, allowing you to surf on the dark side in an old school fashion :D between several big windows, and avoiding to use 'cd' or 'exit' and 'jls' all the time.
More flexible to my eyes.
 
Status
Not open for further replies.
Top