Mike Chambers
Veteran Member
- Joined
- Sep 2, 2006
- Messages
- 2,621
just wondering, under DOS with a FAT16 partition... what is the maximum of files allowed inside of any one directory? what about the partition as a whole?
Define what you mean by a SMTP/POP3 server. What are your client systems going to look like? Do you expect to be able to relay mail to other mail servers on the net?
If you use a lot of small files (one for each message) then you are going to waste a lot of disk space. Files take up multiples of clusters, and unused space at the end of a file is dead space. You are also going to fragment the drive very quickly.
The better way to do it is to put the mail in one big file. But when you delete a message, you don't compact the file - you just leave the hole in the file and fill it in with the next new message. The XT would take too long to compact the file every time you deleted a message.
I don't think this is a great app for the XT. It can't handle the size of modern email, it's painfully slow on disk access, and the CPU can't handle too much work. For an occasional text message it would be fine, but not much more.
Think of it like this - if you had trouble with an IRC server staying up reliably, do you think you can do better with an email server?
thanks for the info... was curious because i am developing a SMTP/POP3 server for DOS, and was considering a couple different ways to store users' message data.
first way was give each user their own subfolder under a mailboxes directory, and each individual message could be stored as it's own seperate file with a unique ID number... i was thinking 16-bit would be enough for that, giving up to 65536 single messages for each user (like that'll ever get filled up) - there would be an index file for each user also, which has the mail headers associated with message and it'd ID number.
I have to agree with MBB, but if you're really determined I'd use either 1 file for everything or at least 1 file per user with separate index/pointer files. I wouldn't even make and reuse holes; just mark deletions as deleted and append additions, and periodically copy undeleted to new files and defrag.
m
Seconded!
But, again, if you've got a 386 you can run FreeBSD 2.7 or something much more appropriate for this (and you don't even have to reinvent the wheel).
If you have that much free time, work on that telnet server you tossed around. THAT would be one hell of a cool trick ("Hey, telnet into my DOS machine!")
the main reason i want to make a mail server is because there's a certain forum that i love to troll because every there is a jerkface, and pretty soon after i make accounts they figure it out and ban me again... can't use the same e-mail to register twice, soooooo.... it'll be handy making new accounts on a whim :D
don't worry, it's not this forum.
but yeah, i mean obviously boeing isn't about to trash their network and replace their mail system with an 8088 but even an XT or 286 mail server would be adequete for a small-scale setup... light traffic, and not a billion people logging in every every 2 minutes.