LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 03-08-2016, 07:05 PM   #1
hydrurga
LQ Guru
 
Registered: Nov 2008
Location: Pictland
Distribution: Linux Mint 21 MATE
Posts: 8,048
Blog Entries: 5

Rep: Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925
Info on htree hash directory indexing in ext4


I'm busy having a look at the ext4 filesystem, but am having problems understanding exactly how the htree hashing system works for indexed directories.

I've had a look around but can't find anything that explains it in sufficiently layman's language for me to get a proper grasp of it.

Does anyone know of any online or offline sources that might help me out with this aspect of the filesystem?
 
Old 03-12-2016, 01:24 PM   #2
hydrurga
LQ Guru
 
Registered: Nov 2008
Location: Pictland
Distribution: Linux Mint 21 MATE
Posts: 8,048

Original Poster
Blog Entries: 5

Rep: Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925
Finally found some decent info.

https://www.kernel.org/doc/ols/2002/...es-425-438.pdf

"A Directory Index of Ext2" by Daniel Phillips (the guy who first developed ext's htree directory indexing, and who's now working on the Tux3 filesystem).

A fascinating read for those who are interested.
 
2 members found this post helpful.
Old 03-12-2016, 06:25 PM   #3
norobro
Member
 
Registered: Feb 2006
Distribution: Debian Sid
Posts: 792

Rep: Reputation: 331Reputation: 331Reputation: 331Reputation: 331
It is an interesting read. Thanks for posting the link.
 
Old 03-12-2016, 08:13 PM   #4
hydrurga
LQ Guru
 
Registered: Nov 2008
Location: Pictland
Distribution: Linux Mint 21 MATE
Posts: 8,048

Original Poster
Blog Entries: 5

Rep: Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925
Quote:
Originally Posted by norobro View Post
It is an interesting read. Thanks for posting the link.
No problem, norobro. Glad you enjoyed it!
 
Old 06-13-2018, 12:16 PM   #5
ddbtek
LQ Newbie
 
Registered: Oct 2010
Location: United States of America
Distribution: rhel, suse, centos, etc.
Posts: 10

Rep: Reputation: 3
How to see if a directory is indexed

You can see if a directory is indexed on an ext4 filesystem with the "lsattr" command:


Code:
WORKSTATION spool # lsattr -d *
-------------e-- anacron
-------------e-- cron
----------I--e-- cups
-------------e-- libreoffice
-------------e-- lintian
-------------e-- lpd
lsattr: Operation not supported While reading flags on mail
----------I--e-- mqueue
-------------e-- mqueue-client
-------------e-- plymouth
-------------e-- rsyslog
-------------e-- samba
The 'I' you see on the /var/spool/mqueue directory shows it is INDEXED. You cannot change this with chattr.

I am still trying to figure out how to create a new indexed directory because I cannot rename mqueue to mqueue1 and create an empty mqueue to purge the mail spool because sendmail won't wrote to the new mqueue directory for some of what it is doing and exits without the "Index" option set.

Thanks,
David
 
1 members found this post helpful.
Old 06-14-2018, 12:58 AM   #6
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,348

Rep: Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749
If you really need to empty the dir, how about stopping the sendmail service, then emptying the existing mqueue dir, then restarting sendmail?
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
[SOLVED] How to disable directory indexing ? naruponk Linux - Security 6 05-04-2010 05:21 AM
Setting up Directory Indexing with Apache? your_shadow03 Linux - Server 27 10-25-2009 08:58 PM
Apache Directory Indexing and Permission? your_shadow03 Linux - Server 1 10-23-2009 01:29 AM
Apache Directory Indexing and permission? your_shadow03 Linux - Newbie 3 10-20-2009 10:30 PM
Directory Indexing Apache bborisovich Linux - Server 2 03-07-2008 08:16 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 02:22 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