Dimension Management in Linux via CLI - Need more suggestions

Phyrax

New Member
Jul 29, 2019
78
0
0
So as most of you know, if you're like me and run a no-bans white-list server where ALL mods are enabled. You run into an issue where you're overloaded with Mystcraft Ages, and RFTools dimensions.

Sometime ago I began looking for something to manage this, and I've yet to be able to find an in-game solution other than RFTools commands, and asking people, "Who owns X dimension". You can imagine how that went.

So, after a chat with someone on my server awhile back he said, "Why don't you do it in linux" and I thought that's a brilliant idea.

I want to prefix this with I'M NOT A SHELL SCRIPTER, I know enough commands to get me by in a server environment. So if you take these commands, or any from anyone else who wishes to share here, we are not responsible for you breaking your server. Do your research!

So far what I've got is this one nifty little command:
Code:
find world/* -maxdepth 0 -type d -mtime +30

Of course this command is executed in the minecraft root directory. But this generates a list of files which haven't been modified in 30 days, hence the mtime command. BUT, you can pipe it to grep and pull ONLY dimension folders like so:
Code:
find world/* -maxdepth 0 -type d -mtime +30 | grep DIM

So, for now this is what I'm doing, but I'm working on a shell script that I hope to have finished before Monday to do the following:
  • Find dimensions ( and RF dimensions ) which are more than X number of days old
  • Generate a report and 'maybe' email the admin
  • Delete said dimensions
I suppose it could use more thought, but any other shell scripters out there, or those who may have already done such a thing, I look forward to hearing from you!
 

reteo

New Member
Jul 29, 2019
380
0
0
You've just taken your first step into a larger world.

Sent from my SPH-L720T using Tapatalk
 

McJty

Over-Achiever
Mod Developer
May 13, 2014
2,015
2,519
228
twitter.com
Note that to correctly remove an RFTools dimension you should also remove it in-game using the /rftdim safedel <id> command in addition to deleting the folders. Otherwise it is possible the dimension will simply get recreated by RFTools when it needs it for whatever reason (for example to check if the receiver in it is still active)
 

GreenZombie

New Member
Jul 29, 2019
2,402
-1
0
Note that to correctly remove an RFTools dimension you should also remove it in-game using the /rftdim safedel <id> command in addition to deleting the folders. Otherwise it is possible the dimension will simply get recreated by RFTools when it needs it for whatever reason (for example to check if the receiver in it is still active)

Do you have an admin command that can list the players that created each dimension?
 

McJty

Over-Achiever
Mod Developer
May 13, 2014
2,015
2,519
228
twitter.com
Do you have an admin command that can list the players that created each dimension?

No. Dimensions are not created by a player. They are created by a machine. The player may not even be online when the machine finishes creating a dimension.
 

GreenZombie

New Member
Jul 29, 2019
2,402
-1
0
That's a nice technical restriction, but rather annoying for admins who have a practical need to track down the owner(s) of dimensions.

Practically, what server admins need is the ability to set a per-user dimension limitation policy. It would be nice if RFTools could start tracking the user who (initiated the) creation of each dimension, Ensure that the machine fails to work if a configured default limit is exceeded, and have a cli by which an admin can grant additional tickets to create dimensions to specific users. Perhaps as a reward.
 

McJty

Over-Achiever
Mod Developer
May 13, 2014
2,015
2,519
228
twitter.com
That's a nice technical restriction, but rather annoying for admins who have a practical need to track down the owner(s) of dimensions.

Practically, what server admins need is the ability to set a per-user dimension restriction policy.

Yes, this has been asked before but the way RFTools works this is hard to do. Machines are currently already tagged with the player who placed down the machine but that doesn't help with shops where dimension builders are put in spawn points for everyone to use or when players share dimension builders.
 

GreenZombie

New Member
Jul 29, 2019
2,402
-1
0
Yes, this has been asked before but the way RFTools works this is hard to do. Machines are currently already tagged with the player who placed down the machine but that doesn't help with shops where dimension builders are put in spawn points for everyone to use or when players share dimension builders.

Let me change hats here from annoyed server admin to evil developer type and suggest that you add a "Owner" dimlet, with a configurable requirement that this dimlet be included when creating an age. Only an admin / server operator would be permitted to create Owner dimlets, using a cli, and requiring a on optional username. An unbound owner dimlet could be bound to a player by the player right clicking with it active. On a server using this feature, one or more owner dimlets could be given to new players.
Well. Something like that.
 
  • Like
Reactions: McJty

McJty

Over-Achiever
Mod Developer
May 13, 2014
2,015
2,519
228
twitter.com
Let me change hats here from annoyed server admin to evil developer type and suggest that you add a "Owner" dimlet, with a configurable requirement that this dimlet be included when creating an age. Only an admin / server operator would be permitted to create Owner dimlets, using a cli, and requiring a on optional username. An unbound owner dimlet could be bound to a player by the player right clicking with it active. On a server using this feature, one or more owner dimlets could be given to new players.
Well. Something like that.

That is actually a good idea. One problem to solve however: after creating a dimension a player can freely extract the dimension tab again and create a new dimension using the dimlets he got back (that is assuming he doesn't want the original dimension since that will no longer receive power). So that means the player can only have one really usable dimension (or as many as he has 'owner' dimlets) but he can still create as many dimensions as he wants by keeping on extracting the tabs.

One way to solve this would be to make sure that owner dimlets cannot be extracted back. That means the player has to be careful though. One bad experiment and he lost his owner dimlet.

But nevertheless, I will consider something like this. It can help a bit