# Sysinstall, Configure, Options.....argh!



## hellsshells (Mar 27, 2011)

Hey everyone,
I just have to ask, it would appear the options still do not save in 8.2, I would hope this is not a per-use type deal, as that's silly considering, when I choose to use sysinstall instead of a cmd line install, that my choice of editor and media path would retain my choices.

All of the FreeBSD versions did this as far as I can remember, since v1!

Rather than dig for hours on end, anyone know where this script is so I can just force it?

I must admit, today I was lucky, it held my choice of editor for the better part of the day, and checking just now, back to ole' vi! Argh!

One-line helpers, thank you in advance. Make me go read tons of man's or online documentation, don't answer this post.

~HB ï¿½e


----------



## phoenix (Mar 28, 2011)

First, stop using sysinstall for anything other than installing the OS.

Second, read the man page for your shell.    It explains how to set things like the *EDITOR* environment variable, so that you can set it to whatever text editor you want.  It will show you which file(s) to edit to put the EDITOR setting into.  For example, the csh uses .cshrc and the Bourne shell uses .shrc and .profile.

Third, be prepared to read if you want to get the most out of FreeBSD.  As the old saying goes, "Give a man a fish, and you feed him for the day.  Teach a man to fish, and you feed him for a lifetime."  You won't find many fish-givers on here.    We're more fish-teachers.


----------



## hellsshells (Mar 28, 2011)

*Sigh.....*

Darn. Somehow I knew I would get a reply like this. My hopes were high when I got the text on my cell phone 

1.First, stop using sysinstall for anything other than installing the OS.
R: Then why have the option at all? Any real UNIX system builder or admin will install, and disregard the chance to install at the end, rather we actually reboot first, make sure there are no issues with the OS on the machine. Then back in to add what we need. I mean, that's common sense right? Why spend all the time adding what you will, to reboot and find out there are serious issues. If I am not mistaken, in the FreeBSD manual, the team actually encourages the use of it. Weird, 8.2 the "default" is just vi, yet this screenshot shows ee for 8.1

http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/using-sysinstall.html

2. I forgot I am talking with super techies and should have added more details. I am well aware of that, .profile .login yep, and I even know how to do it via command-line too!!!  (I am special like that)


```
EDITOR=/usr/local/bin/pico
export EDITOR
```

Yes, at command this DOES work, of course it will. Until that shell is exited, of course on login it will read from the users shells and local configs. Again, adding them to all just never works.

Oddly, adding to them ends up with the same issue, never stays. Added via cmd it will work until you exit that shell session, regardless of what shell. (Yes, even root right from the console before anyone asks) 

I guess it's all about preference, I personally can't stand vi, I am super lazy with keystrokes so pico is my choice.

I know it's not mission critical, it would just be nice that where-ever changes are made, they should stay put. I was hoping to locate the config file, or whatever location stores the settings to add them. 4.1 actually saved. 6.1 would save FTP but not the editor. 8.2 will not store either.

Never heard that one ahah! That's cute! Here's my own.

Contrary to popular belief, there are 3-kinds of people in this world. Talkers, do'ers, and Makers. Makers - we actually make the things that people "talk" about and "do". ~HellsBells!


----------



## DutchDaemon (Mar 28, 2011)

You can also make system-wide shell defaults, e.g. by using /etc/csh.cshrc or /etc/profile, as explained in e.g. csh(1) or bash(1). These are read each time a shell is started, so the settings will remain.


----------



## jb_fvwm2 (Mar 29, 2011)

Just as an aside, one confounded by sysinstall may want to use the 
	
	



```
fdisk -f
```
 (etc) option to setup...

I used sysinstall back in 2004 for a first install.  Once since then, used it for ftp upgrade to a buildworld done wrong. More recently , the 
	
	



```
fdisk -f
```
 I found can fdisk "165" via a file template, (165 is bsd), whereupon various manpages sort of take the sysinstall difficulty out of setting up new disks. (Even the gjournal manpage...).  I've used sysinstall various times on live cd's to repair lost critical files, but 2 of the three versions do not permit writing to a disk easily... etc.  

This narrative neglects to assume an original install by CD or dvd, in hindsight.  My apologies...


----------



## hellsshells (Mar 30, 2011)

Thank you Dutch~
Sadly, no go sir. This old man came crying /home/ heh. Get this, I think it's got something to do with this machines setup. By that I mean the loading of a shell, working from within that shell, and another. From that su - 'ing to root. So, in short, not ten minutes ago, crontab -e argh! vi  

Iv'e put that export everywhere I could  Even /root/.login as my final attempt. Yes sir, even root's .profile. Correct, they are in sys defaults as well. So now I could careless what's not saving in sysinstall, there are other issues at hand.

Iv'e setup a test machine, I would like to see what actually happens if any of the login mechanisms have issues. I will corrupt 2 of the 3 shells they are using and see if a default is enabled. That can be the only reason it's reverting back to install defaults. I am going to start with the login.conf to see what other root's on the machine have changed and run cap_mkdb /etc/login.conf myself to make sure.

Anyway, I will return in a few days with a solid confirmation that it's our fault in some-way. I always blame what's behind the keyboard before what's in front of it.

Thanks
HB~


----------



## SirDice (Mar 30, 2011)

hellsshells said:
			
		

> From that su - 'ing to root. So, in short, not ten minutes ago, crontab -e argh! vi


EDITOR is removed, as are pretty much all the environment variables. See su(1).



> Iv'e put that export everywhere I could  Even /root/.login as my final attempt. Yes sir, even root's .profile.


Try setting it in root's .cshrc. See csh(1). Dot profile is used by Bourne and Korn shells, not C shells.


----------



## Anonymous (Mar 30, 2011)

@hellsshells



> Originally Posted by hellsshells
> 
> ```
> EDITOR=/usr/local/bin/pico
> ...



Did I understand that part correctly, you want to set pico as the default EDITOR on FreeBSD 8.2?

My 8.2 systems do not have pico, but do have /usr/local/bin/nano (the successor of pico) which I had installed from the ports /usr/ports/editors/nano. Pico is even not in the ports. Are you sure, you have pico installed? If not try:

[CMD=""]cd /usr/ports/editors/nano; make install clean[/CMD]
[CMD=""]cd /usr/local/bin; ln -s nano pico[/CMD]

Eventually, to be really safe from vi causing you a heart attack, you could do something like:

[CMD=""]cd /usr/bin; mv vi _vi_; ln -s /usr/local/bin/nano vi[/CMD]

Best regards

Rolf


----------



## phoenix (Mar 30, 2011)

Which is why I mentioned reading the man pages for the shells in question, in order to understand which files are called, and when they are called.  Depending on how you start a shell (login, interactive, non-interactive), it loads different config files, and you get different settings.

For example, login(1) using /bin/sh accesses different files than su(1) to a user using /bin/sh.

Plus, sh(1), ksh(1), csh(1) all use completely different files.


----------



## hellsshells (Mar 31, 2011)

@ rolfheinrich
Yes, pico is part of alpine. It's bundled. Thank you sir.

@ SirDice
Again, it is set in every shells file, system, and a few places I tossed it in for turds and giggles. Thank you sir.

Shells installed:
Shell (sh csh tcsh vshnu bash rbash v7sh sash rssh psh ksh glob6 lshell jk_socketd jsh fdsh esh ch bashc nologin)

There are others installed but hidden from users, and one I have written myself for light 'plan 9' type cluster use.

@ others
Again, I've used FreeBSD since version one. I've RTFM since day-one, and RTFMs of everything since, ergo why I didn't need references to manuals. I admit I left FreeBSD at 6.2 because I was angry with choices made by the dev team, and now at 8.2 I've caught up. I always RTFM before I ask anyone for help. If the manuals helped, I would not be here. Noticed I am 100% new to the forum? If I've not needed help or the forum since its inception, then I must be doing things right all these years   I am rusty right now, not ignorant.

Not that it matters, but the new complete-fresh install on a new machine:
The options (Sysinstall > Conf. > Opt) do not save at all, but again that's not my worry now.

Thanks all, appreciate the quick responses. Unlike the kiddies who took over #freebsd the voices here
are seriously a pleasure.
~HB


----------



## Beastie (Mar 31, 2011)

The options within *sysinstall* are not system configurations, but (default) install configurations as shown on the main menu. I can't see why they should be stored.


----------

