128a129,153
> Exclude_list()
> {
> 	tar_dir="${1}"
> 	exc_list="${2}"
> 	
>         echo "${exc_list}" > "${exc_list}"
> 
>         exlist=""
>         # If /cow, exclude files that could interfere with startup
> 	if [ "${tar_dir}" = "/cow" ]; then
>                 exlist+="^/cow/var/log/ ^/cow/var/lock/ ^/cow/tmp/ "
> 		exlist+="^/cow/var/tmp/ ^/cow/sys/ "
> 		exlist+="^/cow/dev/ ^/cow/cow/ ^/cow/proc/ ^/cow/var/run/ "
> 		exlist+="^/cow/etc/mtab$ ^/cow/var/cache/apt/archives/ "
> 		exlist+="^/cow/var/lib/dhcp./ ^/cow/var/lib/urandom/ "
>         fi
> 
> 	all_files=/tmp/all_files
>         find "${tar_dir}" -print > "${all_files}"
> 	for x in ${exlist}; do
> 	        grep "${x}" "${all_files}" >> "${exc_list}"
>         done
> 	rm -f "${all_files}"
> }
> 
130a156,159
> 
> 	ex_lst=/tmp/exclude_list
> 	Exclude_list "${COW}" "${ex_lst}"
> 
133,136c162,163
< 			echo "./tmp/exclude_list" > /tmp/exclude_list
< 			( cd "${COW}" && find . -name '*.wh.*' >> /tmp/exclude_list )
< 			mksquashfs "${COW}" "${DEST}" -ef /tmp/exclude_list || exit 1
< 			rm /tmp/exclude_list
---
> 			mksquashfs "${COW}" "${DEST}" -noappend -ef "${ex_lst}" || exit 1
> 			rm "${ex_lst}"
236c263
< 		DEST=$(echo "${SNAP_RSTRING}" | cut -f3 -d ':')
---
> 		DEST="${MOUNTP}/$(echo "${SNAP_RSTRING}" | cut -f3 -d ':')"
