Reinstall Freenas 11.2 without losing data on drive

ric

Contributor
Joined
Dec 22, 2013
Messages
180
Ive setup AD in my LAN and decided to try joining my freenas system into AD. While configuring the freenas system permission and account creation somehow the plugins and jails didnt like that. I've spent days on troubleshooting the issues. Id like to reinstall freenas on new USB but how can i add the drive with the data back without losing data? Heres the error messages when I tried to open "Available plugin"

Cmd('git') failed due to: exit code(128) cmdline: git clone -v https://github.com/freenas/iocage-ix-plugins.git /mnt/tank/iocage/.plugin_index stderr: 'Cloning into '/mnt/tank/iocage/.plugin_index'... error: chmod on /mnt/tank/iocage/.plugin_index/.git/config.lock failed: Operation not permitted fatal: could not set 'core.filemode' to 'false' '

Error: concurrent.futures.process._RemoteTraceback:
"""
Traceback (most recent call last):
File "/usr/local/lib/python3.6/site-packages/iocage_lib/ioc_plugin.py", line 1269, in _clone_repo
repo = git.Repo(destination)
File "/usr/local/lib/python3.6/site-packages/git/repo/base.py", line 124, in __init__
raise NoSuchPathError(epath)
git.exc.NoSuchPathError: /mnt/tank/iocage/.plugin_index

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/usr/local/lib/python3.6/site-packages/iocage_lib/ioc_plugin.py", line 636, in __clone_pull_plugin_index
self._clone_repo(self.branch, git_server, git_working_dir, callback=self.callback)
File "/usr/local/lib/python3.6/site-packages/iocage_lib/ioc_plugin.py", line 1307, in _clone_repo
k: v for k, v in kwargs.items() if v
File "/usr/local/lib/python3.6/site-packages/git/repo/base.py", line 982, in clone_from
return cls._clone(git, url, to_path, GitCmdObjectDB, progress, **kwargs)
File "/usr/local/lib/python3.6/site-packages/git/repo/base.py", line 933, in _clone
finalize_process(proc, stderr=stderr)
File "/usr/local/lib/python3.6/site-packages/git/util.py", line 336, in finalize_process
proc.wait(**kwargs)
File "/usr/local/lib/python3.6/site-packages/git/cmd.py", line 418, in wait
raise GitCommandError(self.args, status, errstr)
git.exc.GitCommandError: Cmd('git') failed due to: exit code(128)
cmdline: git clone -v https://github.com/freenas/iocage-ix-plugins.git /mnt/tank/iocage/.plugin_index
stderr: 'Cloning into '/mnt/tank/iocage/.plugin_index'...
error: chmod on /mnt/tank/iocage/.plugin_index/.git/config.lock failed: Operation not permitted
fatal: could not set 'core.filemode' to 'false'
'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/usr/local/lib/python3.6/concurrent/futures/process.py", line 175, in _process_worker
r = call_item.fn(*call_item.args, **call_item.kwargs)
File "/usr/local/lib/python3.6/site-packages/middlewared/worker.py", line 133, in main_worker
res = loop.run_until_complete(coro)
File "/usr/local/lib/python3.6/asyncio/base_events.py", line 484, in run_until_complete
return future.result()
File "/usr/local/lib/python3.6/site-packages/middlewared/worker.py", line 93, in _run
return await self._call(name, serviceobj, methodobj, params=args, job=job)
File "/usr/local/lib/python3.6/site-packages/middlewared/worker.py", line 85, in _call
return methodobj(*params)
File "/usr/local/lib/python3.6/site-packages/middlewared/worker.py", line 85, in _call
return methodobj(*params)
File "/usr/local/lib/python3.6/site-packages/middlewared/schema.py", line 668, in nf
return f(*args, **kwargs)
File "/usr/local/lib/python3.6/site-packages/middlewared/plugins/jail.py", line 544, in list_resource
header=False)
File "/usr/local/lib/python3.6/site-packages/iocage_lib/iocage.py", line 914, in fetch
icon=True, official=official)
File "/usr/local/lib/python3.6/site-packages/iocage_lib/ioc_plugin.py", line 654, in fetch_plugin_index
self.__clone_pull_plugin_index()
File "/usr/local/lib/python3.6/site-packages/iocage_lib/ioc_plugin.py", line 643, in __clone_pull_plugin_index
_callback=self.callback)
File "/usr/local/lib/python3.6/site-packages/iocage_lib/ioc_common.py", line 90, in logit
_callback(content, exception)
File "/usr/local/lib/python3.6/site-packages/iocage_lib/ioc_common.py", line 64, in callback
raise callback_exception(message)
RuntimeError: Cmd('git') failed due to: exit code(128)
cmdline: git clone -v https://github.com/freenas/iocage-ix-plugins.git /mnt/tank/iocage/.plugin_index
stderr: 'Cloning into '/mnt/tank/iocage/.plugin_index'...
error: chmod on /mnt/tank/iocage/.plugin_index/.git/config.lock failed: Operation not permitted
fatal: could not set 'core.filemode' to 'false'
'
"""

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "/usr/local/lib/python3.6/site-packages/middlewared/main.py", line 165, in call_method
result = await self.middleware.call_method(self, message)
File "/usr/local/lib/python3.6/site-packages/middlewared/main.py", line 1096, in call_method
return await self._call(message['method'], serviceobj, methodobj, params, app=app, io_thread=False)
File "/usr/local/lib/python3.6/site-packages/middlewared/main.py", line 1041, in _call
return await self._call_worker(name, *args)
File "/usr/local/lib/python3.6/site-packages/middlewared/main.py", line 1061, in _call_worker
return await self.run_in_proc(main_worker, name, args, job)
File "/usr/local/lib/python3.6/site-packages/middlewared/main.py", line 995, in run_in_proc
return await self.run_in_executor(self.__procpool, method, *args, **kwargs)
File "/usr/local/lib/python3.6/site-packages/middlewared/main.py", line 971, in run_in_executor
return await loop.run_in_executor(pool, functools.partial(method, *args, **kwargs))
RuntimeError: Cmd('git') failed due to: exit code(128)
cmdline: git clone -v https://github.com/freenas/iocage-ix-plugins.git /mnt/tank/iocage/.plugin_index
stderr: 'Cloning into '/mnt/tank/iocage/.plugin_index'...
error: chmod on /mnt/tank/iocage/.plugin_index/.git/config.lock failed: Operation not permitted
fatal: could not set 'core.filemode' to 'false'
'
 

HolyK

Ninja Turtle
Moderator
Joined
May 26, 2011
Messages
654
Hi,

check if /mnt/tank/iocage/.plugin_index/.git exists. If not create the directory manually and give it chmod 775 and try to open the available plugin again..
If the directory exists then check if the config.lock exists. If yes then rename it to something else. If not then OK. Lastly check if the config exists. If yes then check the permissions and give it chmod ug+rw. After that check the plugins again.
 

pschatz100

Guru
Joined
Mar 30, 2014
Messages
1,184
If you are going to do a fresh install of FreeNAS, now would be a good time to migrate the boot device to an SSD. Be certain to save your configuration, and then you can restore it to the new boot device. Flash drives are not reliable boot devices anymore, and they are more unreliable with the newest versions of FreeNAS.

Your data will not be at risk. After you create the new boot device, you can restore the configuration and then remount the drives. The documentation discusses how to do this.
 
Top