> Source: [sk101106](https://support.checkpoint.com/results/sk/sk101106)

# sk101106 - "shell-init: error retrieving current directory..." error when running "cpstop" / "cpstart" / "reboot" commands on Linux-based OS

| Property | Value |
|----------|-------|
| Solution ID | sk101106 |
| Date Created | 2014-06-01 |
| Last Modified | 2015-06-15 |
| Technical Level | General |
| Products | Security Gateway, Security Management Server, Multi-Domain Security Management Server |
| Versions | R82.10, R82, R81.20, R82.10, R82, R81.20, R82.10, R82.20, R81.20, R82, R82.20 |
| OS | Linux, Gaia |

## Symptoms

- The following error might appear multiple times when running "`cpstop`" / "`cpstart`" / "`reboot`" commands on Linux-based OS (e.g., Gaia / SecurePlatform / RHEL / etc.):
`shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory`

## Cause

This happens usually after uninstalling Check Point packages on Linux OS. When the user runs "cpstart", or "reboot" from the same directory as running the "`UnixUninstallScript`" script.

The "`UnixUninstallScript`" script has deleted the current directory (e.g., `/opt/CPUninstall/R77.10`), so that any other command running from that directory (e.g., "cpstart") is prone to show these errors.

Note: This is a general behavior of Linux-based OS (e.g., Gaia / SecurePlatform / RHEL / etc.), when issuing commands from a deleted directory.

## Solution

Before running "`cpstop`" / "`cpstart`" / "`reboot`" commands, change the current directory to any other directory using the "`cd`" command.

*Examples*:

```
# cd /var
# cd /home
```

---

# Agent Instructions

This content is from the Check Point Support Center (https://support.checkpoint.com), the official knowledge base for Check Point cybersecurity products.

## Navigating This Knowledge Base

- **Complete index**: [llms.txt](https://support.checkpoint.com/llms.txt)
- **All SK articles**: [SecureKnowledge Sitemap](https://support.checkpoint.com/sitemaps/secureknowledge-sitemap-index.xml)
- **SK article URL pattern**: `https://support.checkpoint.com/results/sk/{skId}`
- **Markdown responses**: AI bot User-Agents automatically receive `text/markdown` content
