Fails to calculate free space for long mount points
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
easycrypt (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
Binary package hint: easycrypt
easycrypt Version: 0.2.2.5-0ubuntu1
installed onto a standard gutsy system with latest truecrypt installed
My home directory is nfs mounted.
When trying to create a crypt in my home directory it gave the following output:
username@
failed to load localised text, defaulting to English (en)
Easy Crypt 0.2.2.5 (2008/01/23 22:34:45)
root is /usr/share/
home is /home/username/
first run show them the welcome
sudo command will be gksudo
checking : ps -ef | grep "pyt[h]on ./EasyCrypt.py"
looking for truecrypt
found truecrypt
df -k /home/user/ | tail -1 | awk {'print $4'}
size left 99%
Traceback (most recent call last):
File "./EasyCrypt.py", line 1504, in doFirstCreateEvent
self.
File "./EasyCrypt.py", line 872, in getCryptPasswor
spaceleft = self.howMuchSpa
File "./EasyCrypt.py", line 408, in howMuchSpaceInKb
return int(checkAmount
ValueError: invalid literal for int() with base 10: '99%'
This is caused by df using two lines to display long mounted filesystem names.
e.g.
% df -k ~
Filesystem 1K-blocks Used Available Use% Mounted on
fileserver:
A solution is to patch /usr/share/
e.g.
% df -Pk ~
Filesystem 1024-blocks Used Available Capacity Mounted on
fileserver:
Patch:
% diff -u /usr/share/
--- /usr/share/
+++ /usr/share/
@@ -393,8 +393,8 @@
- print "df -k "+self.
- checkAmountLeft = commands.
+ print "df -Pk "+self.
+ checkAmountLeft = commands.
if capMax:
Thanks - I will add this patch to Version 0.2.2.6