Jump to content

Complete stupidity moving files (solved)


Zoc

Recommended Posts

Ok, so during a man cold weaving in and out of a fever i was active in a root SSH session.

See where this is going?

 

With my limited Linux experience I believe I moved my entire root to an array folder..

Had several files on a disk outside the array that i wanted to move to my /movies share.

Within the folder i used "mv /* /user/movies" instead of "mv ./* /user/movies". 

 

Yeah..

 

Neither Web UI or SSH respons, running headless.

Just powered down and removed my Unraid USB drive and accessing if from a Windows computer it's completely empty.

 

Any suggestion on how to resolve this embarrasing stupid mistake?

 

I thank you for any and all help you can give.

Currently both sick and sick of my own stupidity..

 

Regards,

Zoc 😟

Edited by Zoc
Issue resolved
Link to comment

Thanks for the reassuring word. 

I too think my data should be somewhat intact. 

 

Unfortunately I do not have a backup of my USB drive.

That is one of many things I will address once I'm up and running again..

 

My initial idea was to spin up a trial version of unraid to hopefully access my array where most of my files should have ended up. 

Not sure if that would work.. 

 

At this stage though I have made a promise to myself to only gather information and create a plan.

No more actual sever work until my fever is gone. 😊 

Link to comment

Yes that is a good plan.  First reinstall Unraid onto your usb flash device and reboot your server.  If you already have a basic/plus/pro key then install it.  The tricky part is recovering your config.  What was the basic device configuration, meaning, do you know what storage devices were assigned to Parity, data disk, cache?  If cache, was it single-device or multi-device pool?

Link to comment
1 hour ago, Zoc said:

Had several files on a disk outside the array that i wanted to move to my /movies share.

Within the folder i used "mv /* /user/movies" instead of "mv ./* /user/movies". 

Within WHAT folder? What was the exact command you used? It is very unclear whether these files would have gone to the array, since /user is not a path to any disk. The user shares are at /mnt/user.

Link to comment
18 minutes ago, trurl said:

Have you rebooted since this accident? If not, and the destination path was indeed in /user and not /mnt/user, then those files would have gone to RAM, and of course if you have rebooted they are gone.

Good question.  I assumed, having a fever and under influence of cold (and other) medication,  he meant /mnt/user/movies because /user does not exist and 'mv' would complain if that were the case. ;)

Link to comment
10 minutes ago, limetech said:

Good question.  I assumed, having a fever and under influence of cold (and other) medication,  he meant /mnt/user/movies because /user does not exist and 'mv' would complain if that were the case. ;)

This is correct.

Move was towards /mnt/user/movies. 

Command was issued within a folder on a disk mounted outside the array. /mnt/disk(s)/trashdisk/move/ i believe.

As I have done several times before. Correctly that is...

My general setup is 3 disks with one of them as parity and a ssd cache. 

Details beyond that is a bit fussy.. 

My initial setup has been kind to me and I have only been giving it updates and general tcl every quarter or so.

Think my uptime was close to 100 days. 

Server is currently shutdown. 

 

Thank you for your help in this matter. 

Feeling stupid does not mix well with feeling sick. Luckily, as I have been avoiding medication, I have whiskey to ease my suffering. 👍

 

I really do need to sort out my usage, too much unnecessary mucking about as root out of pure convenience..

That goes up on the list on things to improve.

Link to comment
35 minutes ago, Zoc said:

I have whiskey to ease my suffering.

👍

 

Simple solution is to boot a fresh Unraid install (no need even for a Trial key) and then mount each device manually.  For example, first:

mkdir /x   # create a temp mountpoint

Then look at the devices on Main page and mount each one until you find where /boot got moved to, eg:

mount /dev/sdX1 /x   # replace X with a,b,c,d etc, though probably not a, that's probably your boot device
ls /x/movies   # do you see /movies/boot ?
umount /x  # if not, then try next device

Having identified the device where your /boot directory now lives, you can copy the vital contents to your flash device:

cp -r /x/movies/boot/config/* /boot/config

Now sync and reboot and you should be back in business:

sync
reboot

Be sure to reward yourself with another shot of whiskey if this works, and then go to Main/Flash and download a flash backup.

Link to comment

That seems both comprehensible and straight forward. 

Words I seldom use in my more and more frequent visits to the magical land of Linux. 

 

I'll be sure to post an update once I'm in suitable condition to manage such an operation. 

 

I hope that others can learn from my mistake and I'll be a touch more careful and experienced from it. 

👍 

 

For now sleep, which will be more pleasant after this conversation. 

 

Way back when I was recommended Unraid I had a gut feeling that it was the right choice. Years of hassle-free use and your kind help really cement that fact. 

A big thank you for that. 

Link to comment

Update:

limetech's method was sucessful up until the reboot.

Config folder found on one of the array disks and copied to /boot/config/ on the newly recreated flash drive.

After reboot though neither the web interface or the SSH seems to come online.

Could be due to the new flash drive certainly is a newer version of unraid. (6.6.5)

Will repeate the operation with 6.5.3 and also copy all the non-array files of the server in an attempt to stich it together on my laptop if this version fails to finalize boot as well. 

 

 

Edited by Zoc
Unraid versions
Link to comment

Update:

 

Both 6.6.5 and 6.5.3 will not boot up correctly or somehow have issues with the network after config copy sync reboot.

The server never comes online on the network.

 

My best guess is that it's related to my long uptime causing the config folder to somehow be incompatible with newer versions.

Is there anyway to check what unraid version i was running? It might have been as old as 6.4.

Are older unraid versions still availiable for download? Download page only carries three and forum links are dead.

 

The issue could also be related to the license keys as i just dump my old config folder on top of a untouched fresh install.

Haven't even touched the web interface, only connected via SSH.

Should that work? I am using the same actual flash drive as before. Installed using the new USB creator tool.

 

Thanks,

Ola

Edited by Zoc
Link to comment
49 minutes ago, Zoc said:

My best guess is that it's related to my long uptime causing the config folder to somehow be incompatible with newer versions.

Is there anyway to check what unraid version i was running? It might have been as old as 6.4.

I would be very surprised if there were any config file incompatibility between 6.4 and later versions.

 

49 minutes ago, Zoc said:

somehow have issues with the network after config copy

Have you tried the default network.cfg from the download?

 

Also, what was your server name (in config/ident.cfg)?

Link to comment
33 minutes ago, remotevisitor said:

Have you tried booting in Safe mode from the boot menu to make sure the problem isn’t caused by incompatible plugins in your config directory?

^^^ THIS

 

Many plugins aren't even backward compatible beyond some version, much less being forward compatible, so if you have old plugins you should get rid of them. If you get it working without plugins then you can install the latest versions.

 

You can simply rename the config/plugins folder to move them out of the way "permanently" or just boot in SAFE mode to make Unraid skip them for that bootup.

Link to comment
9 hours ago, trurl said:

I would be very surprised if there were any config file incompatibility between 6.4 and later versions.

 

Have you tried the default network.cfg from the download?

 

Also, what was your server name (in config/ident.cfg)?

Here we have it!

Replacing the network.cfg with the default one solved it.

Many thanks @trurl, and many thanks once more to you @limetech.

Server is up and running again 👍

 

Not sure what is causing this incompability or when it was introduced.

Old network.cfg

# Generated network settings
USE_DHCP=yes
IPADDR=
NETMASK=
GATEWAY=

New default network.cfg (From 6.5.3)

# Generated network settings
USE_DHCP="yes"
IPADDR=
NETMASK=
GATEWAY=
BONDING="yes"
BRIDGING="yes"

Not sure what bonding and bridging means though. Running a single network cable.

 

Thanks for all the help and support, most appreciated!

/Zoc

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...