LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 07-30-2014, 12:11 PM   #1
gaurav_s
Member
 
Registered: Jul 2014
Posts: 43

Rep: Reputation: Disabled
shell-init: error retrieving current directory: getcwd


I have a customized command set-active-host in /usr/local/bin dir .
Below is the scenario:-
on terminal1
mkdir /tmp/junk
on terminal2
cd /tmp/junk

on terminal 1

rm -rf /tmp/junk

on terminal 2 i executed the command set-active-host
i get below errors:-
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory Running set-active-host as user root. Please help.

note: other commands like ps and ls are running fine.
 
Old 07-30-2014, 01:03 PM   #2
Habitual
LQ Veteran
 
Registered: Jan 2011
Location: Abingdon, VA
Distribution: Catalina
Posts: 9,374
Blog Entries: 37

Rep: Reputation: Disabled
don't cd /tmp/junk in terminal 2 and the rm should work in terminal 1.

Edit: you can't "rm" some directory if you're in it.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Setting the current directory in an init.d boot script bas_at_cipix Linux - General 1 07-28-2011 01:48 PM
pwd: error retrieving current directory: getcwd: cannot access parent directories: Pe bootkernel Linux - General 1 05-05-2008 06:45 AM
su shell-init: error retrieving current directory: getcwd: cannot access parent direc linuxgentoo Linux - General 4 11-07-2007 02:19 AM
Problem with X consoles - "shell-init: error retrieving current directory" lowpro2k3 Slackware 4 03-26-2007 07:36 PM
symlink-hook: error retrieving current directory: getcwd: cannot access parent dire sailu_mvn Linux - Software 1 03-09-2006 07:01 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 09:22 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration