Changeset 808 in MondoRescue for trunk/mondo/mondo/common
- Timestamp:
- Sep 22, 2006, 11:12:37 PM (18 years ago)
- Location:
- trunk/mondo/mondo/common
- Files:
-
- 4 edited
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
trunk/mondo/mondo/common/libmondo-devices.c
r795 r808 1823 1823 bkpinfo->media_size[i] = atoi(sz_size); 1824 1824 } 1825 paranoid_free(sz_size);1826 1827 if (!popup_and_get_string1828 (_("Prefix."),1829 _("Please enter the prefix that will be prepended to your ISO filename. Example: machine1 to obtain machine1-[1-9]*.iso files"),1830 bkpinfo->prefix)) {1831 log_to_screen("User has chosen not to backup the PC");1832 finish(1);1833 }1834 log_msg(3, "prefix set to %s", bkpinfo->prefix);1835 1825 } else { 1836 1826 for (i = 0; i <= MAX_NOOF_MEDIA; i++) { … … 1839 1829 } 1840 1830 } 1831 if (!popup_and_get_string 1832 ("Prefix.", 1833 "Please enter the prefix that will be prepended to your ISO filename. Example: machine1 to obtain machine1-[1-9]*.iso files", 1834 bkpinfo->prefix, MAX_STR_LEN / 4)) { 1835 log_to_screen("User has chosen not to backup the PC"); 1836 finish(1); 1837 } 1838 log_msg(3, "prefix set to %s", bkpinfo->prefix); 1841 1839 break; 1842 1840 default: -
trunk/mondo/mondo/common/libmondo-fifo.c
r795 r808 158 158 sync(); 159 159 asprintf(&command, 160 "ps | grep -F \"%s\" | grep -Fv grep | awk '{print $1;}' | grep -v PID | tr -s '\n' ' ' | awk '{ print $1; }'", ps_options,160 "ps %s | grep -F \"%s\" | grep -Fv grep | awk '{print $1;}' | grep -v PID | tr -s '\n' ' ' | awk '{ print $1; }'", ps_options, 161 161 g_sz_call_to_buffer); 162 162 paranoid_free(g_sz_call_to_buffer); -
trunk/mondo/mondo/common/libmondo-files.c
r783 r808 1027 1027 /*@ buffers ******** */ 1028 1028 char *nfs_dev = NULL; 1029 char *mac_addr = NULL; 1029 1030 char *nfs_mount = NULL; 1030 1031 char *nfs_client_ipaddr = NULL; … … 1051 1052 1052 1053 asprintf(&nfs_mount, p); 1054 /* BERLIOS : there is a bug #67 here as it only considers the first NIC */ 1053 1055 asprintf(&command, 1054 1056 "ifconfig | tr '\n' '#' | sed s/##// | tr '#' ' ' | tr '' '\n' | head -n1 | cut -d' ' -f1"); … … 1088 1090 } 1089 1091 make_hole_for_dir("/var/cache/mondo-archive"); 1092 /******** 1093 * If the NFS device that found above is a bonded device, 1094 * we need to replace it with an ethN device or the 1095 * networking will not start during an NFS restore. 1096 * 1097 * If the NFS device in nfs_dev begins with the word "bond", 1098 * look for the corresponding slave ethN device and copy it to nfs_dev. 1099 * Using the common MAC address 1100 ********/ 1101 if (!strncmp(nfs_dev, "bond", 4)) { 1102 log_to_screen("Found bonding device %s; looking for corresponding ethN slave device\n", nfs_dev); 1103 asprintf(&command, 1104 "ifconfig %s | awk '{print $5}'", nfs_dev); 1105 mac_addr = call_program_and_get_last_line_of_output(command); 1106 asprintf(&command, 1107 "ifconfig | grep -E '%s' | head -n1 | cut -d' ' -f1", mac_addr); 1108 paranoid_free(nfs_dev); 1109 nfs_dev = call_program_and_get_last_line_of_output(command); 1110 paranoid_free(command); 1111 paranoid_free(mac_addr); 1112 1113 log_to_screen("Replacing it with %s\n", nfs_dev); 1114 } 1090 1115 1091 1116 asprintf(&tmp, "%s/NFS-DEV", bkpinfo->tmpdir); -
trunk/mondo/mondo/common/newt-specific.c
r795 r808 240 240 char *tmp = NULL; 241 241 242 asprintf(&tmp,"kill `ps %s | grep \" " %s "\" | awk '{print $1;}' | grep -vx \"\\?\"`", ps_options, str);242 asprintf(&tmp,"kill `ps %s | grep \" %s \" | awk '{print $1;}' | grep -vx \"\\?\"`", ps_options, str); 243 243 run_program_and_log_output(tmp, TRUE); 244 244 paranoid_free(tmp);
Note:
See TracChangeset
for help on using the changeset viewer.