Sponsored Content
Full Discussion: change login dir
Top Forums UNIX for Dummies Questions & Answers change login dir Post 13876 by Kelam_Magnus on Thursday 24th of January 2002 03:24:58 PM
Old 01-24-2002
If this is for the root user, here is something I discovered the other day.

root:/root> cd
root:/root> echo $HOME
/root
root:/root> HOME=/
root:/root> cd
root:/> echo $HOME
/
root:/> HOME=/root
root:/> cd
root:/root>
root:/root> HOME=/usr/local/bin
root:/root> cd
root:/usr/local/bin> HOME=/root
root:/usr/local/bin> cd
root:/root>


There is a variable called $HOME. You can modify it to be what ever you want. When you type "cd" <enter> that is where you will go. As in the example above.

You can make this permanent by putting in the bottom of your .profile. export HOME=/some/dir.

This works for any user, even root and application user IDs.


Smilie Smilie
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

how I change dir in dos

Hi I have a dos batch file in window server where I call a cmd command for creating some db. this cmd commad is located in e:\data\abcd\xyz.cmd. Now I call this batch file from unix ssh.sh but my access point is D in window server here I want to change the dos prompt to e:\data\abcd. in... (3 Replies)
Discussion started by: Jamil Qadir
3 Replies

2. UNIX for Dummies Questions & Answers

I want to change login failure message, "login incorrect"

I want to change login failure message, "login incorrect" deny user login for user id tom sudo passwd -l tom type username and type password on login prompt and then it will display login failure message "login incorrect" console ############ login: tom password: login incorrect... (2 Replies)
Discussion started by: lifegeek
2 Replies

3. Solaris

cant able to change permission in a DIR as root user

Hi my directory not accepting any commands. its simply telling permission denied. i tried ( cp, mv, rm ) as roor i want to set default permissons to this DIR please find the Logs below. dr-xr-xr-x 1 root root 1 Jun 1 09:04 AP1_ROP ( original dir) root> chmod 777... (5 Replies)
Discussion started by: vijayq8
5 Replies

4. Solaris

Change inherit-pkg-dir to writable

/lib in my sparse zone is running and its inherit-pkg-dir due ti which its readonly is it possible to make it writable if yes how ? (2 Replies)
Discussion started by: fugitive
2 Replies

5. Solaris

How to change permission for opt dir in Solaris Zones?

Hi All While configuring zone I run add inherit-pkg-dir I thing this command will inherit opt,etc,lib... directories from global zone to non global zone with read permission................ So this makes problem for me I want to edit one file opt dir which is useful for my project but when I... (4 Replies)
Discussion started by: vijaysachin
4 Replies

6. Solaris

Requesting help to automatically create home dir on login

I know we would not normally do this. However, I would like to have user's home directory created when they log in the first time. I have searched the forums and have not found any help yet. Scenario - environment uses NIS for auth and usually NFS mount HOME. However, I have a pilot environment... (4 Replies)
Discussion started by: 22blaze
4 Replies

7. HP-UX

could not able change permission of /home dir

Hi i am new to this admin area . i have created user with name as "ab" and gave home dir as /home/ab . when i tried to create the /home/ab dir , i got he following error. "mkdir: Failed to make directory "/home/ab"; Operation not applicable " Thanks in advance . (1 Reply)
Discussion started by: expert
1 Replies

8. Shell Programming and Scripting

Generate a change list of files/dir

Is there a tool that can diff a directory and generate a change list of files in that directory based on a previous snapshot on the directory? For example /etc/a.txt:changed /etc/b.txt:removed /etc/c.txt:added Thanks! (1 Reply)
Discussion started by: overmindxp
1 Replies

9. Solaris

Change Dir doubt and some advice.

Hello, This is my first post in this forum. I need to change the owner of several directories and files in Solaris 10 Operating system, more than 500. The server is in production and my question is: If i change the owner of directories and files, the server can become unstable, i mean,... (2 Replies)
Discussion started by: checoturco
2 Replies

10. HP-UX

[Solved] Unable to change/create home dir for particular user

Hi all I wanted to change the home dir for a user, but when using smh : SMH->Accounts for Users and Groups->Local Users->Modify User ---------------------------------------------------------------------------------------------------------------------------------------------- * Required... (8 Replies)
Discussion started by: fretagi
8 Replies
SYSTEMD-VOLATILE-ROOT.SERVICE(8)                           systemd-volatile-root.service                          SYSTEMD-VOLATILE-ROOT.SERVICE(8)

NAME
systemd-volatile-root.service, systemd-volatile-root - Make the root file system volatile SYNOPSIS
systemd-volatile-root.service /lib/systemd/systemd-volatile-root DESCRIPTION
systemd-volatile-root.service is a service that replaces the root directory with a volatile memory file system ("tmpfs"), mounting the original (non-volatile) /usr inside it read-only. This way, vendor data from /usr is available as usual, but all configuration data in /etc, all state data in /var and all other resources stored directly under the root directory are reset on boot and lost at shutdown, enabling fully stateless systems. This service is only enabled if full volatile mode is selected, for example by specifying "systemd.volatile=yes" on the kernel command line. This service runs only in the initial RAM disk ("initrd"), before the system transitions to the host's root directory. Note that this service is not used if "systemd.volatile=state" is used, as in that mode the root directory is non-volatile. SEE ALSO
systemd(1), systemd-fstab-generator(8), kernel-command-line(7) systemd 237 SYSTEMD-VOLATILE-ROOT.SERVICE(8)
All times are GMT -4. The time now is 02:42 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy