Changeset 2160


Ignore:
Timestamp:
Mar 6, 2009, 10:53:57 AM (10 years ago)
Author:
bruno
Message:
  • Exclude filesystems type ptmpfs and devpts from being parsed. Should solve aproblem seen with large /dev/shm being backed up.
Location:
branches/2.2.9/mondo/src/common
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • branches/2.2.9/mondo/src/common/libmondo-archive.c

    r2095 r2160  
    378378    }
    379379
    380     /*
    381     if (g_tmpfs_mountpt[0] != '\0') {
    382         i = atoi(call_program_and_get_last_line_of_output
    383                  ("df -m -P | grep dev/shm | grep -v none | tr -s ' ' '\t' | cut -f4"));
    384         if (i > 0) {
    385             if (free_ramdisk_space > i) {
    386                 free_ramdisk_space = i;
    387                 log_msg(2, "min(free_ramdisk_space) is now %d",
    388                         free_ramdisk_space);
    389                 if (free_ramdisk_space < 10) {
    390                     fatal_error
    391                         ("Please increase PPCFG_RAMDISK_SIZE in my-stuff.h to increase size of ramdisk ");
    392                 }
    393             }
    394         }
    395     }
    396     */
    397380    paranoid_free(command);
    398381    paranoid_free(zipparams);
  • branches/2.2.9/mondo/src/common/libmondo-filelist.c

    r2133 r2160  
    14051405        // 2.6 has /sys as a proc-type thing -- must be excluded
    14061406        asprintf(&strtmp,
    1407              "find %s -maxdepth %d -fstype mvfs -prune -o -path /dev/shm -prune -o -fstype proc -prune -o -fstype sysfs -prune -o %s -type d -print > %s 2> /dev/null",
     1407             "find %s -maxdepth %d -fstype mvfs -prune -o -fstype devpts -prune -o -fstype tmpfs -prune -o -fstype proc -prune -o -fstype sysfs -prune -o %s -type d -print > %s 2> /dev/null",
    14081408             dir, MAX_SKEL_DEPTH, find_excludes, g_skeleton_filelist);
    14091409#else
  • branches/2.2.9/mondo/src/common/libmondo-tools.c

    r2059 r2160  
    473473    run_program_and_log_output("cat /etc/*-release", 5);
    474474    run_program_and_log_output("cat /etc/*issue*", 5);
    475     /*
    476     sprintf(g_tmpfs_mountpt, "%s/tmpfs", bkpinfo->tmpdir);
    477     sprintf(command, "mkdir -p %s", g_tmpfs_mountpt);
    478     paranoid_system(command);
    479     rdsiz_MB = PPCFG_RAMDISK_SIZE + g_tape_buffer_size_MB;
    480     */
    481475#ifdef __FreeBSD__
    482     /*
    483     strcpy(tmp,
    484            call_program_and_get_last_line_of_output
    485            ("vmstat | tail -1 | tr -s ' ' | cut -d' ' -f6"));
    486     avm += atol(tmp);
    487     strcpy(tmp,
    488            call_program_and_get_last_line_of_output
    489            ("swapinfo | grep -v Device | tr -s ' ' | cut -d' ' -f4 | tr '\n' '+' | sed 's/+$//' | bc"));
    490     avm += atol(tmp);
    491     sprintf(command, "mdmfs -s %d%c md9 %s", rdsiz_MB, 'm',
    492             g_tmpfs_mountpt);
    493             */
    494476#else
    495     /*
    496     strcpy(tmp,
    497            call_program_and_get_last_line_of_output
    498            ("free | grep ':' | tr -s ' ' '\t' | cut -f2 | head -n1"));
    499     avm += atol(tmp);
    500     sprintf(command, "mount /dev/shm -t tmpfs %s -o size=%d%c",
    501             g_tmpfs_mountpt, rdsiz_MB, 'm');
    502             */
    503477    run_program_and_log_output("cat /proc/cpuinfo", 5);
    504478    run_program_and_log_output
     
    506480         5);
    507481#endif
    508     /*
    509     if (avm / 1024 > rdsiz_MB * 3) {
    510         if (run_program_and_log_output(command, 5)) {
    511             g_tmpfs_mountpt[0] = '\0';
    512             log_it("Failed to mount tmpfs");
    513         } else {
    514             log_it("Tmpfs mounted OK - %d MB", rdsiz_MB);
    515         }
    516     } else {
    517         g_tmpfs_mountpt[0] = '\0';
    518         log_it("It doesn't seem you have enough swap to use tmpfs. Fine.");
    519     }
    520     */
    521482
    522483    if (bkpinfo->use_lzo) {
Note: See TracChangeset for help on using the changeset viewer.