List storage space from Reseller - FireStorm ISP

List storage space from Reseller

Support Wissensdatenbank

Du bist hier:
Print

How to find out the allocated storage space in Plesk

 

Here is a guide on how to find out how much disk space you have in Plesk and how much disk space you have already used.

 

Step 1: Log in to the server via SSA.

 

 

Step 2: Then enter the command below. For “Username”, enter the username of the Plesk Reseller.

RESELLER="Username"
plesk db -Ne "select id from clients where parent_id in (select id from clients where login = '$RESELLER') or login = '$RESELLER'" > /tmp/$RESELLER.CLIDS
cat /dev/null > /tmp/$RESELLER.SUBS; cat /tmp/$RESELLER.CLIDS | while read CLID; do plesk db -Ne "select name from domains where cl_id=$CLID and webspace_id=0" >> /tmp/$RESELLER.SUBS; done
cat /dev/null > /tmp/$RESELLER.DUSAGE; cat /tmp/$RESELLER.SUBS | while read SUB; do plesk bin subscription --info $SUB | egrep "Domain name:"\|"Disk space limit:"\|"Size:"\|"Owner's contact name:" >> /tmp/$RESELLER.DUSAGE; echo "---------------------------" >> /tmp/$RESELLER.DUSAGE; done; echo "Stats file: /tmp/$RESELLER.DUSAGE";
cat /dev/null > /tmp/$RESELLER.SUBS; cat /tmp/$RESELLER.CLIDS | while read CLID CLLOGIN; do plesk db -Ne "select id, name from domains where cl_id=$CLID and webspace_id=0" >> /tmp/$RESELLER.SUBS; done >> /tmp/$RESELLER.SUBS
cat /dev/null > /tmp/$RESELLER.disk_space; cat /tmp/$RESELLER.SUBS | while read SUBID SUBNAME; do NEWVAL=`plesk db -Ne "SELECT round(value/1024/1024/1024) FROM Limits WHERE limit_name = 'disk_space' AND id = (SELECT value FROM SubscriptionProperties WHERE name = 'limitsId' AND subscription_id = (SELECT id FROM Subscriptions WHERE object_id = (SELECT id FROM domains WHERE id = $SUBID)))"`; echo -e "[i] $SUBNAME: $NEWVAL GB"; echo $NEWVAL >> /tmp/$RESELLER.disk_space; done

 

 

Step 3: A list is now displayed. You can now see how much storage space has been allocated next to each user name.

 

 

 

 

 

War dieser Artikel hilfreich?
0 out Of 5 Stars
5 Stars 0%
4 Stars 0%
3 Stars 0%
2 Stars 0%
1 Stars 0%
Wie können wir diesen Artikel verbessern?
Please submit the reason for your vote so that we can improve the article.
Brauchst du Hilfe?
Related Post