[Solved]Deleted Windows, Linux boot option gone

Questions about Grub, UEFI,the liveCD and the installer
Forum rules
Before you post please read how to get help
User avatar
WharfRat
Level 20
Level 20
Posts: 11107
Joined: Thu Apr 07, 2011 8:15 pm

Re: Deleted Windows, Linux boot option gone

Post by WharfRat » Sun Dec 10, 2017 5:44 pm

Linux_User157 wrote:I loathe Windows, and don't want to dual boot, but I like gaming. I don't want Wine because of security reasons. I can't use virtualbox because of limited processing power, ram, video ram and other limitations. Do you of anything else? Besides an external hard drive. That is something I was thinking of using.
The only simple solution to your dilemma is to have two computers, one that runs windows and of course the other running linux.

From what I've heard there is no substitute for windows' gaming other than a natively installed windows OS.
Image ImageImage

User avatar
Linux_User157
Level 3
Level 3
Posts: 102
Joined: Sat Oct 21, 2017 12:01 pm

Re: Deleted Windows, Linux boot option gone

Post by Linux_User157 » Sun Dec 10, 2017 6:56 pm

Does an external hard drive count as natively installing Windows?

User avatar
WharfRat
Level 20
Level 20
Posts: 11107
Joined: Thu Apr 07, 2011 8:15 pm

Re: Deleted Windows, Linux boot option gone

Post by WharfRat » Sun Dec 10, 2017 8:02 pm

Linux_User157 wrote:Does an external hard drive count as natively installing Windows?
I imagine it would be since it's not in a virtual environment.
Image ImageImage

User avatar
Linux_User157
Level 3
Level 3
Posts: 102
Joined: Sat Oct 21, 2017 12:01 pm

Re: [Solved]Deleted Windows, Linux boot option gone

Post by Linux_User157 » Fri Dec 15, 2017 8:46 pm

I followed the instructions, but what do I do afterwards? /home/user on my hard drive still seems not to be mounted. I tried the newer ecryptfs-mount-private too. I actually think it IS mounted, It just isn't showing up. Yes, my user name is user, by the way.

User avatar
WharfRat
Level 20
Level 20
Posts: 11107
Joined: Thu Apr 07, 2011 8:15 pm

Re: [Solved]Deleted Windows, Linux boot option gone

Post by WharfRat » Sat Dec 16, 2017 12:17 am

Linux_User157 wrote:I followed the instructions, but what do I do afterwards? /home/user on my hard drive still seems not to be mounted. I tried the newer ecryptfs-mount-private too. I actually think it IS mounted, It just isn't showing up. Yes, my user name is user, by the way.
It's been a few days and I'm getting lost here :?

Are you saying that you can't get to your files in your home folder :?:
Image ImageImage

User avatar
Linux_User157
Level 3
Level 3
Posts: 102
Joined: Sat Oct 21, 2017 12:01 pm

Re: [Solved]Deleted Windows, Linux boot option gone

Post by Linux_User157 » Sat Dec 16, 2017 1:13 pm

Yes. I can't get to the files.

User avatar
WharfRat
Level 20
Level 20
Posts: 11107
Joined: Thu Apr 07, 2011 8:15 pm

Re: [Solved]Deleted Windows, Linux boot option gone

Post by WharfRat » Sat Dec 16, 2017 3:18 pm

Linux_User157 wrote:Yes. I can't get to the files.
OK, try this one line at a time:

Code: Select all

sudo -i
export envvars='opts fnek fnek_sig d sigs mount_sig mount_opts tmpdir'
for o in $envvars;do export "$o=";done; opts=ro;tmpdir=/tmp/mine
/sbin/cryptsetup luksOpen /dev/sdb3 crypt
mount /dev/mapper/mint--vg-root /mnt
For the following replace wharfrat with your user's /home folder name

Code: Select all

d=$(find /mnt/home/.ecryptfs/wharfrat -type d -name ".Private") && echo "$d"   
ls "$d/ECRYPTFS_FNEK_ENCRYPTED"* >/dev/null 2>&1 && fnek="--fnek" || fnek=
ecryptfs-insert-wrapped-passphrase-into-keyring "$d/../.ecryptfs/wrapped-passphrase"  # Enter the user's password when prompted
sigs=$(sed -e "s/[^0-9a-f]//g" "$d/../.ecryptfs/Private.sig") && echo "$sigs"
If you get 1 line with characters and numbers then follow the next three lines

Code: Select all

   mount_sig=$(echo "$sigs" | head -n1) && echo "$mount_sig"
   fnek_sig=
   mount_opts="$opts,ecryptfs_sig=$mount_sig,ecryptfs_cipher=aes,ecryptfs_key_bytes=16" && echo "$mount_opts"
otherwise if the result is two lines then use these

Code: Select all

  mount_sig=$(echo "$sigs" | head -n1) && echo "$mount_sig"
  fnek_sig=$(echo "$sigs" | tail -n1) && echo "$fnek_sig"
  mount_opts="$opts,ecryptfs_sig=$mount_sig,ecryptfs_fnek_sig=$fnek_sig,ecryptfs_cipher=aes,ecryptfs_key_bytes=16" && echo "$mount_opts"

Code: Select all

mkdir "$tmpdir"
mount -i -t ecryptfs -o "$mount_opts" "$d" "$tmpdir"
ls -lh /tmp/mine
Your files should be accessable in /tmp/mine
Image ImageImage

User avatar
Linux_User157
Level 3
Level 3
Posts: 102
Joined: Sat Oct 21, 2017 12:01 pm

Re: [Solved]Deleted Windows, Linux boot option gone

Post by Linux_User157 » Sat Dec 16, 2017 3:42 pm

It worked, but it won't let me move it, and I had to open the folder everything was in with root.

User avatar
WharfRat
Level 20
Level 20
Posts: 11107
Joined: Thu Apr 07, 2011 8:15 pm

Re: [Solved]Deleted Windows, Linux boot option gone

Post by WharfRat » Sat Dec 16, 2017 3:50 pm

Linux_User157 wrote:It worked, but it won't let me move it, and I had to open the folder everything was in with root.
Finally, something actually worked - it's about time :roll:

I don't know if you plan on installing Mint again, but I would suggest a normal unencrypted installation as you just discovered the intricate complexities with an encrypted system.
Image ImageImage

User avatar
Linux_User157
Level 3
Level 3
Posts: 102
Joined: Sat Oct 21, 2017 12:01 pm

Re: [Solved]Deleted Windows, Linux boot option gone

Post by Linux_User157 » Sat Dec 16, 2017 4:04 pm

I'm still using encryption and reinstalling. It's my fault for dual booting and messing with it. But one problem remains. /temp/mine is locked, and even when I open it with root, I don't have the permissions to move it.

User avatar
WharfRat
Level 20
Level 20
Posts: 11107
Joined: Thu Apr 07, 2011 8:15 pm

Re: [Solved]Deleted Windows, Linux boot option gone

Post by WharfRat » Sat Dec 16, 2017 4:17 pm

Linux_User157 wrote:I'm still using encryption and reinstalling. It's my fault for dual booting and messing with it. But one problem remains. /temp/mine is locked, and even when I open it with root, I don't have the permissions to move it.
You can use cp -a /tmp/mine /destination or mount -o remount,rw /tmp/mine
Image ImageImage

User avatar
Linux_User157
Level 3
Level 3
Posts: 102
Joined: Sat Oct 21, 2017 12:01 pm

Re: [Solved]Deleted Windows, Linux boot option gone

Post by Linux_User157 » Sat Dec 16, 2017 4:30 pm

Code: Select all

mint ~ # mount -o remount,rw /tmp/mine
When remounting eCryptfs, you need to pass the mount utility the -i parameter to avoid calling the mount helper
It's comical to me how complicated this is.

User avatar
WharfRat
Level 20
Level 20
Posts: 11107
Joined: Thu Apr 07, 2011 8:15 pm

Re: [Solved]Deleted Windows, Linux boot option gone

Post by WharfRat » Sat Dec 16, 2017 4:55 pm

Linux_User157 wrote:

Code: Select all

mint ~ # mount -o remount,rw /tmp/mine
When remounting eCryptfs, you need to pass the mount utility the -i parameter to avoid calling the mount helper
It's comical to me how complicated this is.
Yea it's never easy with this stuff :roll:

Try this

Code: Select all

umount /tmp/mine
export opts=rw
mount_opts="$opts,ecryptfs_sig=$mount_sig,ecryptfs_fnek_sig=$fnek_sig,ecryptfs_cipher=aes,ecryptfs_key_bytes=16" && echo "$mount_opts"
mount -i -t ecryptfs -o "$mount_opts" "$d" "$tmpdir"
Is there a reason you can't just use cp -a or the file manager if you're not comfortable with the cl:?:
Image ImageImage

User avatar
Linux_User157
Level 3
Level 3
Posts: 102
Joined: Sat Oct 21, 2017 12:01 pm

Re: [Solved]Deleted Windows, Linux boot option gone

Post by Linux_User157 » Sat Dec 16, 2017 5:16 pm

I don't know what cp -a is, the files wouldn't appear in the home directory in my file manager even after I mounted it, and I am comfortable with the terminal. It isn't difficult, just complicated. By that I mean specifically this. Also the last line put out this.

Code: Select all

mint ~ # mount -i -t ecryptfs -o "$mount_opts" "$d" "$tmpdir"
mount: mount point  does not exist

User avatar
WharfRat
Level 20
Level 20
Posts: 11107
Joined: Thu Apr 07, 2011 8:15 pm

Re: [Solved]Deleted Windows, Linux boot option gone

Post by WharfRat » Sat Dec 16, 2017 5:28 pm

Linux_User157 wrote:I don't know what cp -a is, the files wouldn't appear in the home directory in my file manager even after I mounted it, and I am comfortable with the terminal. It isn't difficult, just complicated. Also the last line put out this.

Code: Select all

mint ~ # mount -i -t ecryptfs -o "$mount_opts" "$d" "$tmpdir"
mount: mount point  does not exist
Reboot the live media and go through the setup again here viewtopic.php?f=46&t=258637&p=1401911#p1401852
changing this line for o in $envvars;do export "$o=";done; opts=ro;tmpdir=/tmp/mine to this for o in $envvars;do export "$o=";done; opts=rw;tmpdir=/tmp/mine
Image ImageImage

User avatar
Linux_User157
Level 3
Level 3
Posts: 102
Joined: Sat Oct 21, 2017 12:01 pm

Re: [Solved]Deleted Windows, Linux boot option gone

Post by Linux_User157 » Sun Dec 17, 2017 1:49 pm

Still locked. I tried to manually move a folder out of it using mv, still locked on the desktop. Is it the tmp folder that is locking it? Everything else seems to be locked except for one thing.
Image

User avatar
WharfRat
Level 20
Level 20
Posts: 11107
Joined: Thu Apr 07, 2011 8:15 pm

Re: [Solved]Deleted Windows, Linux boot option gone

Post by WharfRat » Sun Dec 17, 2017 2:56 pm

Don't use move, use copy.

There's no need to use move as copy will do the same as move, i.e,. the files will just remain in /tmp/mine after copying them to the destination location.

Using cp -a will preserve all the original file dates and times if that's important.
Image ImageImage

User avatar
Linux_User157
Level 3
Level 3
Posts: 102
Joined: Sat Oct 21, 2017 12:01 pm

Re: [Solved]Deleted Windows, Linux boot option gone

Post by Linux_User157 » Sun Dec 17, 2017 4:51 pm

Got everything over. One question though. Does the meta data for files you send to people have anything that can lead back to you? I'm assuming no, but I thought I'd ask anyway. Thanks for all the help.

User avatar
WharfRat
Level 20
Level 20
Posts: 11107
Joined: Thu Apr 07, 2011 8:15 pm

Re: [Solved]Deleted Windows, Linux boot option gone

Post by WharfRat » Sun Dec 17, 2017 5:57 pm

Linux_User157 wrote:Got everything over. One question though. Does the meta data for files you send to people have anything that can lead back to you? I'm assuming no, but I thought I'd ask anyway. Thanks for all the help.
Not quite sure about that - I've never checked.
Image ImageImage

Post Reply

Return to “Installation & Boot”