LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 07-03-2022, 07:59 PM   #1
deretsigernu
Member
 
Registered: May 2007
Distribution: Slackware 14.2/-current
Posts: 185

Rep: Reputation: 13
labels switched on two ntfs partitions.


I have two ntfs partitions, one with Windows 10 ("W10") and the other just a storage space.

I want the W10 partition to be "ntfsc" and the extra space to be "ntfsd". The labels are the reverse of what I want them to be for the two partitions, but that seems to depend on how I'm looking at the partitions.

If I just ls from terminal.

Code:
root@rine:~# ls /ntfsc
$RECYCLE.BIN  DumpStack.log.tmp            jwindoc  pictures           tracks  System\ Volume\ Information  music    projects_and_data  software
The folders listed should be in the /ntfsd partition.

The size of the partitions appear to match what I'd expect. And the MOUNTPOINTS seem to be correct here. I don't know why.
Quote:
root@rine:~# lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTS
sda 8:0 0 465.8G 0 disk
├─sda1 8:1 0 499M 0 part
├─sda2 8:2 0 100M 0 part /boot/efi
├─sda3 8:3 0 16M 0 part
├─sda4 8:4 0 148.6G 0 part /ntfsd
├─sda5 8:5 0 50.4G 0 part /
├─sda6 8:6 0 261.2G 0 part /ntfsc
└─sda7 8:7 0 4.9G 0 part [SWAP]
sr0 11:0 1 1024M 0 rom

root@rine:~# cat /etc/fstab
/dev/sda7 swap swap defaults 0 0
/dev/sda5 / ext4 defaults 1 1
/dev/sda2 /boot/efi vfat defaults 1 0
/dev/sda4 /ntfsd ntfs3 fmask=111,dmask=000 1 0
/dev/sda6 /ntfsc ntfs3 fmask=133,dmask=022 1 0
#/dev/cdrom /mnt/cdrom auto noauto,owner,ro,comment=x-gvfs-show 0 0
/dev/fd0 /mnt/floppy auto noauto,owner 0 0
devpts /dev/pts devpts gid=5,mode=620 0 0
proc /proc proc defaults 0 0
tmpfs /dev/shm tmpfs nosuid,nodev,noexec 0 0

root@rine:~# fdisk -l
Disk /dev/sda: 465.76 GiB, 500107862016 bytes, 976773168 sectors
Disk model: WDC WD5000LPLX-6
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier: B4732C27-ED4C-4E7F-8E93-2C3C46ECA60B

Device Start End Sectors Size Type
/dev/sda1 2048 1023999 1021952 499M Windows recovery environment
/dev/sda2 1024000 1228799 204800 100M EFI System
/dev/sda3 1228800 1261567 32768 16M Microsoft reserved
/dev/sda4 1261568 312909558 311647991 148.6G Microsoft basic data
/dev/sda5 312909824 418705407 105795584 50.4G Linux filesystem
/dev/sda6 418705408 966481509 547776102 261.2G Microsoft basic data
/dev/sda7 966481920 976773134 10291215 4.9G Linux swap
root@passerine:~#
I tried as root

Code:
umount /dev/sda4
umount /dev/sda6
ntfslabel /dev/sda4 "ntfs-d"
ntfslabel /dev/sda6 "ntfs-c"
reboot
That didn't change anything.

I don't know why using the terminal with ls points to the wrong directories when I use the labels I've mentioned. Same with Dolphin in KDE. In Dolphin, if I navigate to ntfsc, I have the folders I'd expect with ntfsd. Sorry, it's confusing since some functions seem to point to the right directory and some don't.
 
Old 07-03-2022, 08:30 PM   #2
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,700

Rep: Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895
Code:
/dev/sda4 1261568 312909558 311647991 148.6G Microsoft basic data
/dev/sda6 418705408 966481509 547776102 261.2G Microsoft basic data

/dev/sda4 /ntfsd ntfs3 fmask=111,dmask=000 1 0
/dev/sda6 /ntfsc ntfs3 fmask=133,dmask=022 1 0

├─sda4 8:4 0 148.6G 0 part /ntfsd
├─sda6 8:6 0 261.2G 0 part /ntfsc
You did not change anything so I am not sure what other results you were expecting.

From a basic logical point of view it would make sense that /dev/sda4 would be the Windows C: drive and /dev/sda6 the d: drive. It is possible to change drive assignments from Windows.

A filesystem label is independent of the directory mount point. Unless you change the /etc/fstab file /dev/sda4 will be mounted to /ntfsd at start up. If you want to mount them by label use:
Code:
LABEL=ntfs-d  /ntfsd ntfs3 fmask=111,dmask=000 1 0
LABEL=ntfs-c  /ntfsc ntfs3 fmask=111,dmask=000 1 0
The output of the blkid and well as the lsblk -f commands will show the device and label information.

Last edited by michaelk; 07-03-2022 at 08:33 PM.
 
Old 07-03-2022, 09:09 PM   #3
deretsigernu
Member
 
Registered: May 2007
Distribution: Slackware 14.2/-current
Posts: 185

Original Poster
Rep: Reputation: 13
It turns out I labeled them incorrectly in the setup when I did the reinstall. I haven't used them in a while and I had forgotten which was which when I tried to guess the label to assign just based on the size of the drives. Thanks for your help, michaelk.
 
  


Reply

Tags
ntfs, pathinfo



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Remove "dots" from labels in Cinnamon .window-list-item-labels LenHoff Linux - Software 2 10-30-2020 08:03 PM
Commands to check and change labels of partitions rng Linux - General 3 03-20-2013 10:01 AM
Desktop & window labels & drop-down menus switched into French kjmorris Ubuntu 5 03-04-2012 07:33 PM
1. how to set labels bottom margin? 2. how to set all labels to be right to left typi dfgfdgdf General 0 03-20-2007 09:43 AM
Retrieving msdos, vfat and ntfs labels katmandu Linux - Software 5 10-05-2004 11:29 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 03:57 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration