Go Back   DaemonForums > FreeBSD > FreeBSD General

FreeBSD General Other questions regarding FreeBSD which do not fit in any of the categories below.

Thread Tools Display Modes
  #1   (View Single Post)  
Old 15th August 2008
giga giga is offline
Port Guard
Join Date: May 2008
Posts: 11
Thanked 0 Times in 0 Posts
Default Stupid question about FreeBSD

What for there are .cshrc and .profile files in a root "/" folder?
Reply With Quote
  #2   (View Single Post)  
Old 15th August 2008
anomie's Avatar
anomie anomie is offline
Join Date: Apr 2008
Location: Texas
Posts: 445
Thanked 69 Times in 46 Posts

Someone with a little more context/history may have a better explanation, but here's my guess.

First, notice that /.cshrc is hardlinked to /root/.cshrc.
> ls -i /root/.cshrc /.cshrc
9 /.cshrc	9 /root/.cshrc
Now, imagine booting the system to single-user mode, where no filesystems other than / are mounted. I'd imagine (but I have not tested this) that /.cshrc will be executed (assuming csh is used as root's shell), so any nice customizations you've made in /root/.cshrc will still be there in single-user mode.

Other explanations will follow I'm sure.
Kill your t.v.
Reply With Quote
  #3   (View Single Post)  
Old 16th August 2008
peenworm's Avatar
peenworm peenworm is offline
Port Guard
Join Date: Jul 2008
Posts: 12
Thanked 1 Time in 1 Post

/root is in the / filesystem, and the .cshrc will execute from whatever is the user's homedir in the passwd db (/root), so I don't see much benefit from having a copy of .cshrc in /
Reply With Quote
  #4   (View Single Post)  
Old 16th August 2008
BSDfan666 BSDfan666 is offline
Real Name: N/A, this is the interweb.
Helpful companion
Join Date: Apr 2008
Location: Ontario, Canada
Posts: 2,223
Thanked 193 Times in 184 Posts

As said by anomie, the files are used in single user mode... you have all the powers of root, but you're not exactly that user.. meaning, / is effectively your home directory.
Reply With Quote
  #5   (View Single Post)  
Old 16th August 2008
arch arch is offline
Port Guard
Join Date: Jun 2008
Posts: 38
Thanked 2 Times in 2 Posts

just to share a little bit of my experience - when added user with pw and forgot to specify home dir after login the user home dir is /
Verbose mode can also be turned on for SSH2 with the (surprise!) VerboseMode keyword.
Reply With Quote

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
FreeBSD-8.0-BETA1 Install Question. MetalHead FreeBSD Installation and Upgrading 0 9th July 2009 06:23 PM
external drive partition question + fdisk question gosha OpenBSD General 15 15th June 2009 02:00 PM
Few question about freebsd and pcbsd garfield270584 FreeBSD Installation and Upgrading 58 31st March 2009 06:37 PM
Question about some stupid dependancies ivanatora FreeBSD General 2 17th August 2008 07:40 PM
Question about FreeBSD 7 and older HP Hardware. EvoIX_MR2006 FreeBSD Installation and Upgrading 1 17th June 2008 07:37 PM

All times are GMT. The time now is 11:57 AM.

Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2016, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick