azure-cli: [CloudShell] Error on every command run on Azure Cloud Shell: OSError: [Errno 30] Read-only file system
This is autogenerated. Please review and update as needed.
Describe the bug
When I go to run any command on the system it errors out and prevents me from using the cloud shell interface.
Command Name Any command at all
Errors:
The command failed with an unexpected error. Here is the traceback:
[Errno 30] Read-only file system: '/home/**Redacted Username**/.azure/commands/2020-06-05.22-24-38.unknown_command.211.log'
Traceback (most recent call last):
File "/opt/az/lib/python3.6/site-packages/knack/cli.py", line 215, in invoke
cmd_result = self.invocation.execute(args)
File "/opt/az/lib/python3.6/site-packages/azure/cli/core/commands/__init__.py", line 511, in execute
load_cmd_tbl_func=self.commands_loader.load_command_table, args=args)
File "/opt/az/lib/python3.6/site-packages/knack/cli.py", line 164, in raise_event
func(self, **kwargs)
File "/opt/az/lib/python3.6/site-packages/azure/cli/core/azlogging.py", line 86, in init_command_file_logging
self._init_command_logfile_handlers(cmd_logger, args) # pylint: disable=protected-access
File "/opt/az/lib/python3.6/site-packages/azure/cli/core/azlogging.py", line 108, in _init_command_logfile_handlers
logfile_handler = logging.FileHandler(log_file_path)
File "/opt/az/lib/python3.6/logging/__init__.py", line 1032, in __init__
StreamHandler.__init__(self, self._open())
File "/opt/az/lib/python3.6/logging/__init__.py", line 1061, in _open
return open(self.baseFilename, self.mode, encoding=self.encoding)
OSError: [Errno 30] Read-only file system: '/home/**Redacted Username**/.azure/commands/2020-06-05.22-24-38.unknown_command.211.log'
To Reproduce:
Steps to reproduce the behavior. Note that argument values have been redacted, as they may contain sensitive information.
- I don’t know how to reproduce the errors. I just get the error every time I put in a command.
Expected Behavior
I expected all the commands to not error out on run.
Environment Summary
Cloud Shell
Additional Context
About this issue
- Original URL
- State: open
- Created 4 years ago
- Reactions: 2
- Comments: 33 (4 by maintainers)
Yes, I can reproduce the problem and a fix/workaround: 1/ Delete the group “cloud-shell-storage-westeurope” in which the “Storage account” for the Cloud Shell has been created. 2/ Wait for the deletion. 3/ Go back to Cloud Shell and click “Create storage”. 4/ See the issue by typing (for instance):
5/ Restart Cloud Shell with the “power” button/icon. 6/ Check that the issue is fixed by typing (for instance):
Hope this help.
@patricekrakow does this only occur the first time you are connecting to the new file share? My guess is that you are deleting the old file share, creating the new file share, then cloud shell is giving you the session before it has finished making the updates to the storage account settings for the new file share.
I don’t believe this would be resolved by reopening Cloud Shell or using an alternative browser. Please see my comment earlier in this thread for troubleshooting steps.
I did the commands these were my outputs:
Command with test.txt
I had also tried to install az aks install-cli and I got this out