Ignore:
Timestamp:
Sep 21, 2017, 10:15:56 AM (3 years ago)
Author:
mabarracus
Message:

Avoid errors when gui is interrupted

File:
1 edited

Legend:

Unmodified
Added
Removed
  • n4d-lliurexberry/trunk/fuentes/install/usr/sbin/create_llxberry_sd

    r5892 r5893  
    66temp_dir="/tmp/llxberry_${today}_${data_version}_${diff_version}"
    77
    8 if [ -f "${temp_dir}/.lock" ];then
    9     logger "Unable to run 'create_llxberry_sd', ${temp_dir} is locked!"
    10     exit 1
    11 else
    12     if [ ! -d "${temp_dir}" ]; then
    13         mkdir -p ${temp_dir}/fs
    14     fi
    15     touch ${temp_dir}/.lock
     8if [ -f "${temp_dir}/.lock" ]; then
     9    logger "Warning 'create_llxberry_sd', ${temp_dir} is locked! Creating random workdir!"
     10    temp_dir=${temp_dir}_$RANDOM
    1611fi
    1712
     13if [ ! -d "${temp_dir}" ]; then
     14    mkdir -p ${temp_dir}/fs
     15fi
     16touch ${temp_dir}/.lock
    1817
    1918if [ ! -e /var/run/remove_partitions ]; then
Note: See TracChangeset for help on using the changeset viewer.