1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-03-21 14:50:08 +03:00

Create dirs in tm_mkswap (#106)

git-svn-id: http://svn.opennebula.org/one/trunk@518 3034c82b-c49b-4eb3-8279-a7acafdc01c0
This commit is contained in:
Javier Fontán Muiños 2009-05-13 13:18:08 +00:00
parent 8a547d4d7e
commit 3fa925ec63

View File

@ -29,6 +29,11 @@ fi
. $TMCOMMON
DST_PATH=`arg_path $DST`
DST_DIR=`dirname $DST_PATH`
log "Creating directory $DST_DIR"
exec_and_log "mkdir -p $DST_DIR"
exec_and_log "chmod a+w $DST_DIR"
log "Creating ${SIZE}Mb image in $DST_PATH"
exec_and_log "dd if=/dev/zero of=$DST_PATH bs=1 count=1 seek=${SIZE}M"