runltp cleanup() can't remove ${TMP}
A message that is not in the archive (sent off-list or not yet received): [email protected]
hi,
I executed runltp command in my box, everything is OK, but when
cleaning the environment, got following errors:
###############################################################
Done executing testcases.
LTP Version: 20130503
###############################################################rm: cannot remove `/tmp/ltp-9NAwvmAbI5/moulTfFCf/mnt_4458': Device or resource busy
rm: cannot remove `/tmp/ltp-9NAwvmAbI5/sandbox': Device or resource busy
Because /tmp/ltp-9NAwvmAbI5/moulTfFCf/mnt_4458 and /tmp/ltp-9NAwvmAbI5/sandbox are still mounted, so can't delete them, the best way is:
# umount /tmp/ltp-9NAwvmAbI5/moulTfFCf/mnt_4458 # umount /tmp/ltp-9NAwvmAbI5/sandbox
and then:
[ "$LOOP_DEV" ] && losetup -d $LOOP_DEV
[ -e "${TEMP}/test.img" ] && rm -f ${TEMP}/test.img
rm -rf ${TMP}Signature · 3 lines
Best Regards, Eko --
------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:
Build for Windows Store.
http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list
Quoted 17 lines · Eko
hi,
I executed runltp command in my box, everything is OK, but when cleaning
the environment, got following errors:############################################################### Done executing testcases. LTP Version: 20130503 ###############################################################rm: cannot remove `/tmp/ltp-9NAwvmAbI5/moulTfFCf/mnt_4458': Device or resource busy
rm: cannot remove `/tmp/ltp-9NAwvmAbI5/sandbox': Device or resource busyBecause
/tmp/ltp-9NAwvmAbI5/moulTfFCf/mnt_4458and/tmp/ltp-9NAwvmAbI5/sandboxare still mounted, so can't delete them, the best way is:
Quoted 10 lines
# umount /tmp/ltp-9NAwvmAbI5/moulTfFCf/mnt_4458 # umount /tmp/ltp-9NAwvmAbI5/sandboxand then:
[ "$LOOP_DEV" ] && losetup -d $LOOP_DEV [ -e "${TEMP}/test.img" ] && rm -f ${TEMP}/test.img rm -rf ${TMP}
I have seen the same when dealing with a mount/ext4-fs issue (turned out to be a BASHISM) and reading the code.
$TEMP is never used, it should be $TMP.
BTW, this line - which needs to be corrected...
[ -e "${TEMP}/test.img" ] && rm -f ${TEMP}/test.img
...makes no real sense, when doing...
rm -rf ${TMP}
...afterwards :-).
If you look at the code, for me it was not clear what $TMP reflects/is, please look closer.
I remember darkly, it was swapped somewhere...
BTW, I have seen a lot of discrepancy in coding-style, beginning with comments, etc.
The code was touched by different coders, so everyone seems to leave a bit from his/her style.
# DO NOT INDENT/DEDENT!
# ^^DO NOT INDENT/DEDENT!^^
That should be changed to sth like "DO NOT INDENT/DEDENT - OR I KILL YOU!" <--- /me just kidding
Unfortunately, I had a wait.h-issue in Linux-next to go through.
Anyway, runltp needs some more love.
- Sedat -
Quoted 9 lines
--
Best Regards,
Eko
--------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:
Quoted 8 lines
Build for Windows Store.
http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list
------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:
Build for Windows Store.
http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list
Hi!
Quoted 1 line
Anyway, runltp needs some more love.
I keep saying that runltp needs rewrite because both ltp-pan and runltp script are beyond the point of repair and I keep them only in maintenance state.
Now I do plan to start working on replacement and I've posted RFC with some notes on desing to this list about four months ago [1], I haven't started to sketch the code yet but I hope to start working on this soon enough.
[1] http://sourceforge.net/mailarchive/message.php?msg_id=30508383
Meanwhile some other posible functionality emerged. I would like to have better anotated the runtest files adding not only timeouts but also groups to ease runnings only tests for some kind of functionality.
Signature · 13 lines
Cyril Hrubis [email protected] ------------------------------------------------------------------------------ See everything from the browser to the database with AppDynamics Get end-to-end visibility with application monitoring from AppDynamics Isolate bottlenecks and diagnose root cause in seconds. Start your free trial of AppDynamics Pro today! http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk _______________________________________________ Ltp-list mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/ltp-list
Hi!
Quoted 3 lines
BTW, this line - which needs to be corrected...
[ -e "${TEMP}/test.img" ] && rm -f ${TEMP}/test.img
I've just pushed a patch that removes this line.
Signature · 13 lines
Cyril Hrubis [email protected] ------------------------------------------------------------------------------ See everything from the browser to the database with AppDynamics Get end-to-end visibility with application monitoring from AppDynamics Isolate bottlenecks and diagnose root cause in seconds. Start your free trial of AppDynamics Pro today! http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk _______________________________________________ Ltp-list mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/ltp-list
Hi!
Quoted 11 lines
I executed runltp command in my box, everything is OK, but when
cleaning the environment, got following errors:############################################################### Done executing testcases. LTP Version: 20130503 ###############################################################rm: cannot remove `/tmp/ltp-9NAwvmAbI5/moulTfFCf/mnt_4458': Device or resource busy
rm: cannot remove `/tmp/ltp-9NAwvmAbI5/sandbox': Device or resource busy
Quoted 6 lines
Because
/tmp/ltp-9NAwvmAbI5/moulTfFCf/mnt_4458and/tmp/ltp-9NAwvmAbI5/sandboxare still mounted, so can't delete them, the best way is:# umount /tmp/ltp-9NAwvmAbI5/moulTfFCf/mnt_4458 # umount /tmp/ltp-9NAwvmAbI5/sandbox
This looks like leftover mount from some testcases. We need to find which testcases are these and fix them to do their cleanup correctly.
Quick greping suggested that candidates are:
testscripts/test_fs_bind.sh
testcases/kernel/syscalls/mount/mount*.c
Signature · 13 lines
Cyril Hrubis [email protected] ------------------------------------------------------------------------------ See everything from the browser to the database with AppDynamics Get end-to-end visibility with application monitoring from AppDynamics Isolate bottlenecks and diagnose root cause in seconds. Start your free trial of AppDynamics Pro today! http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk _______________________________________________ Ltp-list mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/ltp-list
A message that is not in the archive (sent off-list or not yet received): CA+icZUUtv3MpiYScqqHmLbOFaEqKRC8eSAtUziMrVcRP80kbGw@mail.gmail.com
Hi!
Quoted 21 lines
Quoted 21 lines
Quoted 11 lines
I executed runltp command in my box, everything is OK, but when
cleaning the environment, got following errors:############################################################### Done executing testcases. LTP Version: 20130503 ###############################################################rm: cannot remove `/tmp/ltp-9NAwvmAbI5/moulTfFCf/mnt_4458': Device or resource busy
rm: cannot remove `/tmp/ltp-9NAwvmAbI5/sandbox': Device or resource busyQuoted 6 lines
Because
/tmp/ltp-9NAwvmAbI5/moulTfFCf/mnt_4458and/tmp/ltp-9NAwvmAbI5/sandboxare still mounted, so can't delete them, the best way is:# umount /tmp/ltp-9NAwvmAbI5/moulTfFCf/mnt_4458 # umount /tmp/ltp-9NAwvmAbI5/sandboxThis looks like leftover mount from some testcases. We need to find which testcases are these and fix them to do their cleanup correctly.
Quoted 8 lines
Quoted 6 lines
Quick greping suggested that candidates are:
testscripts/test_fs_bind.sh
testcases/kernel/syscalls/mount/mount*.cSo ${TEMP} is really used?
I don't think so, it looks like a typo to me.
The error messages here are from the 'rm -rf ${TMP}' that is done after the line with ${TEMP}.
Anyway the line that removes the image is both wrong and useless as the whole ${TMP} is removed right after it. I suggest removing it.
Signature · 13 lines
Cyril Hrubis [email protected] ------------------------------------------------------------------------------ See everything from the browser to the database with AppDynamics Get end-to-end visibility with application monitoring from AppDynamics Isolate bottlenecks and diagnose root cause in seconds. Start your free trial of AppDynamics Pro today! http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk _______________________________________________ Ltp-list mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/ltp-list