Jump to content

(SOLVED) Moving data to encrypted drive


Kir

Recommended Posts

Since the in-place encryption is not currently supported, I added a new drive to the array, formatted it to xfs/enc, and in the process of moving data as such:

mv /mnt/disk1 /mnt/disk4

 

My plan is to format disk1 to xfs/enc after the data transfer is completed. What would be the proper procedure of doing it, considering that I have 2 parity drives in the array?

My thoughts would be:

1. Stop the array

2. Select disk1 and change the format to xfs/enc

3. Start the array and format the drive

 

... but how would the array react to it, would it try to reconstruct it with empty data after it's back online?

Link to comment
31 minutes ago, Kir said:

... but how would the array react to it, would it try to reconstruct it with empty data after it's back online?

 

No. You can stop the array, change the format of a disk and start the array without any problems. It wouldn't rebuild the disk unless you deliberately unassigned it, started the array with it unassigned, stopped the array and reassigned it.

  • Like 1
Link to comment
1 minute ago, Kir said:

PS: Just found something weird.... I just found a new user share - disk1 (shows up encrypted). It's not empty, and I definitely did not create it myself.

 

What can I do with it?

Pretty sure you did create it. I'll bet you copied the disk1 folder instead of the contents of disk1 to disk4 at some point, and any folder in the root of an array drive is a user share.

 

What is inside it?

Link to comment

Well, the data transfer finished, so I issued this command: "mv /mnt/disk4/disk1/ .." and got lots of messages "mv: error writing No space left on device"

(I thought it would work as rename, so no additional space needed?)

Interrupted the command, and now array is gone. Main page shows "Array undefined"

 

Syslog: lots of messages

"Nov 29 12:21:02 Storage root: error: /webGui/include/DeviceList.php: uninitialized csrf_token"

followed by:

Nov 29 12:21:07 Storage rc.diskinfo[5243]: PHP Warning: file_put_contents(): Only 0 of 3049 bytes written, possibly out of free disk space in /etc/rc.d/rc.diskinfo on line 499

 

Help?

Link to comment
6 minutes ago, Kir said:

Well, the data transfer finished, so I issued this command: "mv /mnt/disk4/disk1/ .." and got lots of messages "mv: error writing No space left on device"

(I thought it would work as rename, so no additional space needed?)

Interrupted the command, and now array is gone. Main page shows "Array undefined"

 

Syslog: lots of messages

"Nov 29 12:21:02 Storage root: error: /webGui/include/DeviceList.php: uninitialized csrf_token"

followed by:

Nov 29 12:21:07 Storage rc.diskinfo[5243]: PHP Warning: file_put_contents(): Only 0 of 3049 bytes written, possibly out of free disk space in /etc/rc.d/rc.diskinfo on line 499

 

Help?

I think the command should be "mv /mnt/disk4/disk1/* ..".   (note the extra asterisk)!

Link to comment
20 minutes ago, Kir said:

mv /mnt/disk4/disk1/ ..

or

11 minutes ago, itimpi said:

mv /mnt/disk4/disk1/* ..

both have .. as the destination.

 

But .. is relative to the directory you are typing the command in, not relative to the source directory.

 

No way for us to know where you put that stuff. Might even be in RAM so you better find it before rebooting.

 

Do you know what directory you were in when you did the mv?

 

1 minute ago, Kir said:

So what should I do now... with the "Array undefined"

Where are you seeing that? Possibly you overwrote the OS which can be solved with a reboot probably but where did those files go?

Link to comment
Just now, Kir said:

I can't really be sure since there were almost 8Tb of them. However, I don't see them anywhere in /mnt

I wouldn't expect them to be in /mnt unless your current working directory were in /mnt. But there are a lot of other places you could have been when you typed that command. If you were in /boot/config for example, then .. would have referred to /boot, which would be the top folder of your flash drive.

 

If you were in /mnt, then .. would be in the root of the OS filesystem, where lots of folders exist that are actually in RAM and have nothing do with your storage.

 

The error you got 

Quote

possibly out of free disk space in /etc/rc.d/rc.diskinfo

I don't know if that meant it was trying to write into that folder in /etc (which is one of those OS folders in RAM) or if that just means it was out of space somewhere.

 

You mentioned a syslog. Do you have any more of it you could share?

 

Maybe just reboot and hope for the best.

Link to comment

Probably you wouldn't have actually overwritten anything in the OS since a file path collision would be very unlikely. But I don't know why it would think the array was undefined in that case. And there is still the possibility that some of your files were moved to RAM even if they didn't overwrite anything.

Link to comment

Sure... Plus it didn't take the reboot command from webUI...

Nov 29 13:27:15 Storage root: error: /webGui/include/DeviceList.php: uninitialized csrf_token
Nov 29 13:27:15 Storage root: error: /webGui/include/DeviceList.php: uninitialized csrf_token
Nov 29 13:27:15 Storage root: error: /plugins/dynamix.system.temp/include/SystemTemp.php: uninitialized csrf_token
Nov 29 13:27:15 Storage root: error: /webGui/include/DeviceList.php: uninitialized csrf_token
Nov 29 13:27:15 Storage root: error: /plugins/preclear.disk/Preclear.php: uninitialized csrf_token
Nov 29 13:27:15 Storage root: error: /plugins/preclear.disk/Preclear.php: uninitialized csrf_token
Nov 29 13:27:15 Storage root: error: /plugins/preclear.disk/Preclear.php: uninitialized csrf_token
Nov 29 13:27:15 Storage root: error: /plugins/unassigned.devices/UnassignedDevices.php: uninitialized csrf_token
Nov 29 13:27:15 Storage root: error: /plugins/unassigned.devices/UnassignedDevices.php: uninitialized csrf_token
Nov 29 13:27:15 Storage root: error: /plugins/unassigned.devices/UnassignedDevices.php: uninitialized csrf_token
Nov 29 13:27:15 Storage root: error: /webGui/include/Notify.php: uninitialized csrf_token
Nov 29 13:27:16 Storage root: error: /plugins/preclear.disk/Preclear.php: uninitialized csrf_token
Nov 29 13:27:16 Storage root: error: /webGui/include/Notify.php: uninitialized csrf_token
Nov 29 13:27:17 Storage root: error: /plugins/unassigned.devices/UnassignedDevices.php: uninitialized csrf_token
Nov 29 13:27:18 Storage root: error: /plugins/unassigned.devices/UnassignedDevices.php: uninitialized csrf_token
Nov 29 13:27:19 Storage root: error: /webGui/include/DeviceList.php: uninitialized csrf_token
Nov 29 13:27:19 Storage root: error: /plugins/unassigned.devices/UnassignedDevices.php: uninitialized csrf_token
Nov 29 13:27:20 Storage root: error: /plugins/unassigned.devices/UnassignedDevices.php: uninitialized csrf_token
Nov 29 13:27:21 Storage root: error: /plugins/preclear.disk/Preclear.php: uninitialized csrf_token
Nov 29 13:27:21 Storage root: error: /plugins/unassigned.devices/UnassignedDevices.php: uninitialized csrf_token
Nov 29 13:27:22 Storage root: error: /webGui/include/DeviceList.php: uninitialized csrf_token
Nov 29 13:27:22 Storage root: error: /plugins/unassigned.devices/UnassignedDevices.php: uninitialized csrf_token
Nov 29 13:27:23 Storage root: error: /plugins/unassigned.devices/UnassignedDevices.php: uninitialized csrf_token
Nov 29 13:27:24 Storage root: error: /plugins/unassigned.devices/UnassignedDevices.php: uninitialized csrf_token
Nov 29 13:27:25 Storage root: error: /webGui/include/DeviceList.php: uninitialized csrf_token
Nov 29 13:27:25 Storage root: error: /plugins/dynamix.system.temp/include/SystemTemp.php: uninitialized csrf_token
Nov 29 13:27:25 Storage root: error: /plugins/unassigned.devices/UnassignedDevices.php: uninitialized csrf_token
Nov 29 13:27:26 Storage root: error: /plugins/preclear.disk/Preclear.php: uninitialized csrf_token
Nov 29 13:27:26 Storage root: error: /plugins/preclear.disk/Preclear.php: uninitialized csrf_token

 

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...