[SOLVED] bash help: rsync only if device mounted

Hi,
First bash-script here - the tldp.org-guide has gotten me somewhere already, but the final condition 'if rsync...' seems to fail and I don't know why. The script checks if the location to backup the files to is a mountpoint. If not, the script should mount it or die. If it is a mountpoint, rsync should be run.
#!/bin/bash
## VARIABLES
# Set location to backup from
BACKUP_FROM="/srv/media/"
# Set location to backup to
BACKUP_TO="/media/backup/media/"
BACKUP_DEV="e3434573-ad6f-4c44-8168-391292ba5ec5"
BACKUP_MNT="/media/backup"
# Log file
LOG_FILE="/var/log/script_sync_media.log"
## SCRIPT
# Check if the log file exists
if [ ! -e $LOG_FILE ]; then
touch $LOG_FILE
fi
# Check if the drive is mounted
if [[ `! mountpoint -q $BACKUP_MNT` ]]; then
echo "$(date "+%Y-%m-%d %k:%M:%S") - Backup device needed mounting!" >> $LOG_FILE
# If not, mount the drive
if [[ `mount -U $BACKUP_DEV $BACKUP_MNT` ]]; then
echo "$(date "+%Y-%m-%d %k:%M:%S") - Backup device mounted." >> $LOG_FILE
else
echo "$(date "+%Y-%m-%d %k:%M:%S") - Unable to mount backup device." >> $LOG_FILE
exit
fi
fi
# Start entry in the log
echo "$(date "+%Y-%m-%d %k:%M:%S") - Sync started." >> $LOG_FILE
# Start sync
if [[ `rsync -a --delete $BACKUP_FROM $BACKUP_TO` ]]; then
echo "$(date "+%Y-%m-%d %k:%M:%S") - Sync completed succesfully." >> $LOG_FILE
else
echo "$(date "+%Y-%m-%d %k:%M:%S") - Sync failed." >> $LOG_FILE
fi
# End entry in the log
echo "" >> $LOG_FILE
exit
It is probably a trivial problem for a bash-professional? The log states 'Sync started.' and immediately 'Sync failed.'...
Thx.
Vincent
Last edited by zenlord (2011-03-05 15:29:41)

OK, a little bit later than I should have replied, but I have incorporated the tips provided above, and a few other changes:
* added an extra check for the target dir
* applied general exit codes
* added unmount after running the script (which makes the earlier warning if the device nees to be mounted a little superfluous)
Here goes:
#!/bin/bash
## VARIABLES
# Set source location
BACKUP_FROM="/srv/media/"
# Set target location
BACKUP_TO="/media/backup/media/"
BACKUP_DEV="xxxxxxx-xxxxx-xxxxxxxxxxxxxxx" #UUID of the disk
BACKUP_MNT="/media/backup"
# Log file
LOG_FILE="/var/log/script_sync_media.log"
## SCRIPT
# Check that the log file exists
if [ ! -e "$LOG_FILE" ]; then
touch "$LOG_FILE"
fi
# Check that source dir exists and is readable.
if [ ! -r "$BACKUP_FROM" ]; then
echo "$(date "+%Y-%m-%d %k:%M:%S") - ERROR: Unable to read source dir." >> "$LOG_FILE"
echo "$(date "+%Y-%m-%d %k:%M:%S") - ERROR: Unable to sync." >> "$LOG_FILE"
echo "" >> "$LOG_FILE"
exit 1
fi
# Check that target dir exists and is writable.
if [ ! -w "$BACKUP_TO" ]; then
echo "$(date "+%Y-%m-%d %k:%M:%S") - ERROR: Unable to write to target dir." >> "$LOG_FILE"
echo "$(date "+%Y-%m-%d %k:%M:%S") - ERROR: Unable to sync." >> "$LOG_FILE"
echo "" >> "$LOG_FILE"
exit 1
fi
# Check if the drive is mounted
if ! mountpoint "$BACKUP_MNT"; then
echo "$(date "+%Y-%m-%d %k:%M:%S") - WARNING: Backup device needs mounting!" >> "$LOG_FILE"
# If not, mount the drive
if [ mount -U "$BACKUP_DEV" "$BACKUP_MNT" ]; then
echo "$(date "+%Y-%m-%d %k:%M:%S") - Backup device mounted." >> "$LOG_FILE"
else
echo "$(date "+%Y-%m-%d %k:%M:%S") - ERROR: Unable to mount backup device." >> "$LOG_FILE"
echo "$(date "+%Y-%m-%d %k:%M:%S") - ERROR: Unable to sync." >> "$LOG_FILE"
echo "" >> "$LOG_FILE"
exit 1
fi
fi
# Start entry in the log
echo "$(date "+%Y-%m-%d %k:%M:%S") - Sync started." >> "$LOG_FILE"
# Start sync
if rsync -a -v --delete "$BACKUP_FROM" "$BACKUP_TO" &>> "$LOG_FILE"; then
echo "$(date "+%Y-%m-%d %k:%M:%S") - Sync completed succesfully." >> "$LOG_FILE"
else
echo "$(date "+%Y-%m-%d %k:%M:%S") - ERROR: rsync-command failed." >> "$LOG_FILE"
echo "$(date "+%Y-%m-%d %k:%M:%S") - ERROR: Unable to sync." >> "$LOG_FILE"
echo "" >> "$LOG_FILE"
exit 1
fi
# Unmount the drive so it does not accidentally get damaged or wiped
if [ umount "$BACKUP_MNT" ]; then
echo "$(date "+%Y-%m-%d %k:%M:%S") - Backup device unmounted." >> "$LOG_FILE"
else
echo "$(date "+%Y-%m-%d %k:%M:%S") - WARNING: Backup device could not be unmounted." >> "$LOG_FILE"
fi
# End entry in the log
echo "" >> "$LOG_FILE"
exit 0
Usage:
1. c/p to a .sh-file
2. Make the file executable (chmod +x <file>.sh)
3. set an entry in crontab to run this script daily/weekly/monthly
Maybe this little script helps other bash newbies...
Last edited by zenlord (2012-09-23 21:08:32)

Similar Messages

  • [Solved] USB 3 (uPD720200) only detects devices at boot time.

    Hello. I have an HP Probook 4530s laptop with an onboard USB 3 port. A device that is plugged into it before boot shows up in lsusb and can be used normally, but hotplugging a device will not work.
    Relevant outputs after booting with a drive plugged in, unplugging and plugging it back in:
    $ lspci | grep "USB 3.0"
    26:00.0 USB controller: NEC Corporation uPD720200 USB 3.0 Host Controller (rev 04)
    $ lsusb | grep "3.0"
    Bus 003 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
    $ lsusb | grep "LaCie"
    (a distinct lack of drive)
    $ dmesg | egrep "xhci|usb 3"
    [ 0.735878] xhci_hcd 0000:26:00.0: xHCI Host Controller
    [ 0.735887] xhci_hcd 0000:26:00.0: new USB bus registered, assigned bus number 2
    [ 0.736076] xhci_hcd 0000:26:00.0: irq 19, io mem 0xd4500000
    [ 0.736149] xhci_hcd 0000:26:00.0: irq 46 for MSI/MSI-X
    [ 0.736156] xhci_hcd 0000:26:00.0: irq 47 for MSI/MSI-X
    [ 0.736162] xhci_hcd 0000:26:00.0: irq 48 for MSI/MSI-X
    [ 0.736460] xHCI xhci_add_endpoint called for root hub
    [ 0.736462] xHCI xhci_check_bandwidth called for root hub
    [ 0.736574] xhci_hcd 0000:26:00.0: xHCI Host Controller
    [ 0.736578] xhci_hcd 0000:26:00.0: new USB bus registered, assigned bus number 3
    [ 0.739804] xHCI xhci_add_endpoint called for root hub
    [ 0.739806] xHCI xhci_check_bandwidth called for root hub
    [ 1.443390] usb 3-1: new SuperSpeed USB device number 2 using xhci_hcd
    [ 1.459034] usb 3-1: Parent hub missing LPM exit latency info. Power management will be impacted.
    [ 484.575852] usb 3-1: USB disconnect, device number 2
    Any ideas?
    Last edited by codl (2012-12-06 16:30:09)

    I have the exact same usb controller and it seems to be very buggy in linux. The output of lsusb sometimes shows 2 usb 3.0 hubs, sometimes 1 usb 3.0 hub and often no usb 3.0 at all. Also it shows a lot of usb 1.1 controllers, but my mainboard only has usb 3.0 and 2.0. Hotplugging usb 3.0 devices works, but they only run at usb 3.0 speeds and booting with plugged devices often makes them dissapear.
    I recently searched for the issue and found out flashing the usb controller firmware could possibly help.
    http://askubuntu.com/questions/161862/n … untu-12-04
    However you have to download the driver from a third-party website and boot a dos operating system to do the firmware flash, which held me off from doing it.
    Last edited by teateawhy (2012-12-06 13:08:02)

  • [solved]bash help please: sort files & recognize duplicates

    Hi!
    I'm trying to move/rename all files in a folder and its subfolder by age.  And move duplicate files somewhere else. The output looks mostly fine, the tmp files too... but I can't figure out, why the duplicate files handling isn't working. edit: the line that sets the new name (&& newname="$1/.dupes/$dname/$part1_$part2_$fname" \) just doesn't seem to get executed here...
    #!/bin/bash
    pushd "$1" && {
    rafi="/tmp/$RANDOM.size.md5.list" && echo > "$rafi"
    find $1 -type f -print0 | while read -d $'\0' file;
    do \
    fname=$(basename "$file")
    dname=$(dirname "$file")
    part1=$(stat -c%y "$file" | awk -F " |:|\\\.|-" '{printf $1"-"$2"-"$3}')
    part2=$(stat -c%y "$file" | awk -F " |:|\\\.|-" '{printf $4"-"$5"-"$6}')
    echo "$bname" | grep -q "$part1" && part1=""
    echo "$bname" | grep -q "$part2" && part2=""
    newname="$1/$part1/$part2_$fname"
    size="size$(stat -c%s "$file")"
    grep -q "$size" "$rafi" \
    md5="md5$(md5sum -b "$file" | sed "s/ .*//")"
    grep -q "$md5" "$rafi" \
    && newname="$1/.dupes/$dname/$part1_$part2_$fname" \
    || {
    echo "$md5" >> "$rafi"
    } || {
    echo "$size" >> "$rafi"
    newname=$(echo "$newname" | sed "s/\/\/*/\//g" | sed "s/\.~.~//g")
    if [ "$newname" != "$file" ];
    then if ! [ -d $(dirname "$newname") ]
    then echo mkdir -p $(dirname "$newname") -v
    fi
    echo mv "$file" "$newname" -v --backup=numbered
    fi
    done
    popd
    What am I doing wrong? Been trying for hours - I just don't get it...
    Thanks!
    Last edited by whoops (2011-03-01 10:19:48)

    thx, that brought me a little closer!
    juster wrote:I don't usually say this for bash but your style is hard to read.
    Oops... thought so - never had an easy time writing readable code. Or readable anything... Maybe this is not as bad:
    #!/bin/bash
    if pushd "$1"
    then
    # random tmp file for filesize + md5
    rafi="/tmp/$RANDOM.size.md5.list" && echo > "$rafi"
    # for all files in folder $1 + subfolders...
    find $1 -type f -print0 | while read -d $'\0' file
    do
    fname=$(basename "$file")
    dname=$(dirname "$file")
    # Get year-month-day
    part1=$(stat -c%y "$file" | awk -F " |:|\\\.|-" '{printf $1"-"$2"-"$3}')
    # Get hour-minute-second
    part2=$(stat -c%y "$file" | awk -F " |:|\\\.|-" '{printf $4"-"$5"-"$6}')
    # Don't add this info to new filename if it is already in old filename
    echo "$bname" | grep -q "$part1" && part1=""
    echo "$bname" | grep -q "$part2" && part2=""
    # Destination filename
    newname="$1/$part1/${part2}_$fname"
    size="size$(stat -c%s "$file")"
    # have files with the same size already been processed?
    if grep -q $size "$rafi"
    then
    md5="md5$(md5sum -b "$file" | sed "s/ .*//")"
    # have files with the same md5 already been processed?
    if grep -q $md5 "$rafi"
    # set different destination for duplicate files
    then newname="$1/.dupes/$dname/${part1}_${part2}_$fname"
    # write md5 to tmp file
    else echo $md5 >> "$rafi"
    fi
    # write size to tmp file
    else echo "$size" >> "$rafi"
    fi
    # remove double slashes
    newname=$(echo "$newname" | sed "s/\/\/*/\//g" | sed "s/\.~.~//g")
    if [ "$newname" != "$file" ]
    then if ! [ -d $(dirname "$newname") ]
    then echo mkdir -p $(dirname "$newname") -v
    fi
    echo mv "$file" "$newname" -v --backup=numbered
    fi
    done
    popd
    fi
    Renaming seems to work correctly now, but it's still only giving me one "dupe mv line" for my test in /etc/X11 and it's not giving me any for the many duplicates in my huge digicam folder.
    $ sort_by_date /etc/X11/
    ~
    mkdir -p /etc/X11/2011-02-27 -v
    mv /etc/X11/xorg.conf.bak /etc/X11/2011-02-27/19-43-36_xorg.conf.bak -v --backup=numbered
    mkdir -p /etc/X11/2010-06-21 -v
    mv /etc/X11/xorg.conf.d/20-nvidia.conf /etc/X11/2010-06-21/10-12-35_20-nvidia.conf -v --backup=numbered
    mkdir -p /etc/X11/2010-08-24 -v
    mv /etc/X11/xorg.conf.d/10-evdev.conf /etc/X11/2010-08-24/15-45-35_10-evdev.conf -v --backup=numbered
    mkdir -p /etc/X11/2010-09-01 -v
    mv /etc/X11/xorg.conf.d/20-nvidia.conf.pacnew /etc/X11/2010-09-01/12-16-10_20-nvidia.conf.pacnew -v --backup=numbered
    mkdir -p /etc/X11/2010-11-30 -v
    mv /etc/X11/xorg.conf.d/20-keyboard.conf /etc/X11/2010-11-30/10-27-00_20-keyboard.conf -v --backup=numbered
    mkdir -p /etc/X11/2010-05-26 -v
    mv /etc/X11/xorg.conf.d/10-quirks.conf /etc/X11/2010-05-26/21-51-03_10-quirks.conf -v --backup=numbered
    mkdir -p /etc/X11/2010-01-03 -v
    mv /etc/X11/xorg.conf /etc/X11/2010-01-03/10-56-25_xorg.conf -v --backup=numbered
    mkdir -p /etc/X11/.dupes/etc/X11 -v
    mv /etc/X11/xorg.conf.dub /etc/X11/.dupes/etc/X11/2011-02-27_19-43-52_xorg.conf.dub -v --backup=numbered
    mkdir -p /etc/X11/2010-07-10 -v
    mv /etc/X11/Xsession /etc/X11/2010-07-10/20-01-30_Xsession -v --backup=numbered
    mkdir -p /etc/X11/2010-12-22 -v
    mv /etc/X11/xinit/xinitrc.d/30-dbus /etc/X11/2010-12-22/15-39-41_30-dbus -v --backup=numbered
    mkdir -p /etc/X11/2010-11-28 -v
    mv /etc/X11/xinit/xinitrc.d/40-libcanberra-gtk-module /etc/X11/2010-11-28/02-44-08_40-libcanberra-gtk-module -v --backup=numbered
    mkdir -p /etc/X11/2010-12-19 -v
    mv /etc/X11/xinit/xserverrc /etc/X11/2010-12-19/11-58-47_xserverrc -v --backup=numbered
    mkdir -p /etc/X11/2010-11-15 -v
    mv /etc/X11/xinit/xinitrc /etc/X11/2010-11-15/11-39-17_xinitrc -v --backup=numbered
    ~
    Still don't get it where this problem could be coming from...
    md5sum * 2>/dev/null | sort -k 1 | uniq -d -w 32 | cut -c 35-
    That's beautiful, just I have no idea how to use it in the context of what I'm trying to do.
    Last edited by whoops (2011-02-28 13:00:27)

  • [SOLVED] Need help setting default boot device in bios

    I have two harddrives S0 and S1 my windows partition is on S0 and my archlinux and grub is on S1. The problem is that I can't set the default boot device to S1 only S0. I have to F8 everytime I start up. Is there a way to set S1 as my default boot device. I tried searching this on google but I couldn't find any relevant posts
    Thanks,
    Shrub
    Last edited by shrubuntu (2012-12-27 15:03:26)

    DSpider wrote:
    Hi and welcome to the forum.
    I have never heard of the term "S0" and "S1" for drives. Perhaps you mean sda and sdb.
    Go into the BIOS, choose your equivalent of "Hard disk priority", move the drive that you want to boot first above the rest of the others, and then exit by saving the settings (usually F10). That should do the trick. Alternatively, you could open up the case and move the SATA cables around, but be careful if you use "sdx" name conventions in /etc/fstab.
    Thanks for the reply
    I made up S0 and S1 for simplicity. sda and sdb makes more sense I suppose.
    My BIOS does not recognize sdb in the priority menu, I'll try moving the SATA cables.

  • How do I mark question as helpful? Only "this solved my problem" is showing on the answer.

    How do I mark question as helpful? Only "this solved my problem" is showing on the answer.

    Yes, ONLY two  "This helped me" can be clicked.
    Only ONE This solved my question" can be clicked.
    Message was edited by: b j t

  • After update iPhone4 to iOS6, its stuck, showing only USB to iTunes on the screen. What to do, how to solve problem, help

    after update iPhone4 to iOS6, its stuck, showing only USB to iTunes on the screen. What to do, how to solve problem, help 

    Connect your phone to iTunes on your computer like the diagram has indicated and restore the phone

  • Can't connect to ITunes store, this is the only techie device I have, no computer, (only at work), no IPad, no IPod, I have tried the numerous suggestions HELP!

    Can't connect to the ITunes store, I have tried the numersous suggestions and tips but still can't get it to work.  My IPhone is the only techie device I have, no IPad, no IPod and I only have a computer at work!  HELP!

    Close your iTunes,
    Go to command Prompt -
    (Win 7/Vista) - START/ALL PROGRAMS/ACCESSORIES, right mouse click "Command Prompt", choose "Run as Administrator".
    (Win XP SP2 n above) - START/ALL PROGRAMS/ACCESSORIES/Command Prompt
    In the "Command Prompt" screen, type in
    netsh winsock reset
    Hit "ENTER" key
    Restart your computer.
    If you do get a prompt after restart windows to remap LSP, just click NO.
    Now launch your iTunes and see if it is working now.
    If you are still having these type of problems after trying the winsock reset, refer to this article to identify which software in your system is inserting LSP:
    Apple software on Windows: May see performance issues and blank iTunes Store
    http://support.apple.com/kb/TS4123?viewlocale=en_US

  • "mount: only root can mount" or "Unprivileged user can not mount NTFS"

    I'm trying to set up an NTFS partition to use as a common data partition between Arch and Windows. I have it added to fstab so that any user in the ntfsuser group can have access to it, but if it gets unmounted accidentally from the "eject" symbol in the nautilus gui, you have to sudo to mount it back up. Is there a way for it to be remounted automatically when you click on the partition again in Nautilus? I've searched all through the forums and looked through several articles on the wiki but haven't been able to come up with anything. The error I get says
    mount: only root can mount /dev/sda4 on /home/adam/UserData
    I've tried adding the users option to fstab, but that only manages to change the error to
    Unprivileged user can not mount NTFS block devices using the external FUSE
    library. Either mount the volume as root, or rebuild NTFS-3G with integrated
    FUSE support and make it setuid root. Please see more information at
    http://ntfs-3g.org/support.html#unprivileged
    I've tried the suggestions at the link in the error, as well as tried the solutions given in [solved] Gnome : mounting NTFS partition as user and a few other posts, but still nothing. If possible, I'd prefer to stay away from the users option in fstab, since it adds a redundant link to the sidebar in nautilus with a different name.

    @Mr.Elendig: It is mounted through fstab normally, but in nautilus there's an eject icon on the sidebar next to the name of the drive which I've accidentally clicked on a couple times if I'm just trying to open the drive real quick. Once its been unmounted like that it won't let me remount unless I use sudo. I'm just looking for something to make it a little more convenient than having to pop open a cli and type in a password.
    I'll try the suid root when I get home tonight, otherwise I'll look into autofs.

  • Root device mounted successfully, but /sbin/init does not exist ???

    I'm having the issue where when I boot after doing a fresh install, it gives me:
    ERROR: Root device mounted successfully, but /sbin/init does not exist
    Bailing out, you are on your own. Good luck
    sh: can't access tty; job control turned off
    [rootfs /]#
    My fstab:
    # /etc/fstab
    # <file system> <dir> <type> <options> <dump> <pass>
    # /dev/sda1 LABEL=homerroot
    UUID=877deab9-624d-4e1d-90a1-ccc1d6ebc0c6 / ext4 rw,relatime,data=ordered 0 1
    # /dev/sda2 LABEL=homerboot
    UUID=77835da5-8a38-44c1-bf27-bb657df4484b /boot ext4 rw,relatime,data=ordered 0 2
    # /dev/sda3 LABEL=homeretc
    UUID=8a1b5bd8-b147-41e0-87df-70a4a9e12df2 /etc ext4 rw,relatime,data=ordered 0 2
    # /dev/sda4 LABEL=homervar
    UUID=8eb2e7b1-cdf1-46ce-9dc1-439d002bfae4 /var ext4 rw,relatime,data=ordered 0 2
    # /dev/sda5 LABEL=homerusr
    UUID=bce162b4-d27f-450c-a0e6-4d3ebc6242dc /usr ext4 rw,relatime,data=ordered 0 2
    # /dev/sda6 LABEL=home
    UUID=62de76ab-b6d4-4e3d-a423-c287b81813a9 /home ext4 rw,relatime,data=ordered 0 2
    # /dev/sda7 LABEL=public
    UUID=d98a9c8e-2301-4e66-8c7f-26167633a4b0 /public ext4 rw,relatime,data=ordered 0 2
    This looks fine to me, but when /dev/sda1 is mounted at /new_root, none of the other devices are mounted....
    I don't know if this is what's causing the problem since /etc, and /usr are on separate partitions from root, but
    this would be the first time I get a problem dividing things this way (on ubuntu, mint, fedora, et cetera).
    So I tried:
    https://bbs.archlinux.org/viewtopic.php … 3#p1283343
    I get "* is owned by filesystem 2013.05-2" for all three dirs from step three.
    None of the other steps have any effect....
    I also tried:
    https://bbs.archlinux.org/viewtopic.php?id=172943
    My /dev/sda1 mounts to new_root, so I don't think I'm having his problem.
    And:
    https://bbs.archlinux.org/viewtopic.php?id=166423
    I reinstalled systemd-sysvcompat, and I'm sure that's not my problem.
    Interestingly enough, /usr/lib/systemd/systemd is an elf file on my target hard disk.
    Is this an outdated issue or something? Or should /usr/lib/systemd/systemd be a text file?
    Thanks in advance for your help guys!

    WorMzy wrote:Oh, and /usr/lib/systemd/systemd is supposed to be an ELF binary. Not sure why you think it should be a text file.
    I saw another thread saying that adding an entry there would help. I think it was "init=<something>".
    WonderWoofy wrote:A separate /etc is not supported whatsoever.  There needs to be initial access to a few things there.  I'm sure it could be made to work with some initramfs hackery.  But it is neither supported or wise to do so IMO.
    I'll not do the separate partitions then. Thanks. I'll check back if it works/doesn't-works.

  • HT1420 I have set up iTunes Match on only 3 devices (my Windows 7 desktop and 2 iPhones) and am now trying to authorise my new Windows 8 (Toshiba) laptop but I keep failing to authorise the laptop using my one-and-only Apple ID. Does anyone have advice to

    I have set up iTunes Match on only 3 devices (my Windows 7 desktop and 2 iPhones) and am now trying to authorise my new Windows 8 (Toshiba) laptop but I keep failing to authorise the laptop using my one-and-only Apple ID. Does anyone have advice to solve this problem?!

    Hi all.  I can’t tell you how to solve your iCloud 3.x issues.  Heck, I don’t think they’re even solvable.
    But if you had a previous version of iCloud that was working correctly then I can definitely tell you how to solve the “iCloud Photo Stream is not syncing correctly to my Windows 7 PC” problem.  …without even a re-boot.
    Log out of iCloud 3.0 and uninstall it.
    Open My Computer and then open your C:\ drive.  Go to Tools/Folder Options and click on the View tab.  Select the “Show hidden…” radio button and click on OK.
    Open the Users folder.
    Open your user folder
    Open ProgramData (previously hidden folder)
    Open the Apple folder – not the Apple Computer folder.
    Open the Installer Cache folder
    In Details view sort on Name
    Open the folder for the newest entry for iCloud Control Panel 2.x – probably 2.1.2.8 dated 4/25/2013
    Right click on iCloud64.msi and select Install.
    When finished, the synching between iCloud and your PC will be back to working perfectly as before the 3.0 fiasco.  The pictures will be synched to the same Photostream folder as before the “upgrade”.  Now all you need to do is wait until Apple/Microsoft get this thing fixed and working before you try the 3.x upgrade again.
    I think the iCloud 3.0 software was written by the same folks who wrote healthcare.gov with the main difference being that healthcare.gov might eventually be made to work.
    For those of you who hate to go backwards, think of it as attacking to the rear.  Which would you rather have, the frustration of no synching or everything working on an older version?
    Good luck…

  • Bluetooth acting very strange. Only one device works at a time.

    HI,
    I have a bluetooth device in my macmini. And also now have airport.
    But it seems only one device can connect at a time.
    But if a keep turning the 2 dvices ona nd off and mucking around with them then eventuly both work at the same time. One being an apple wireless KB the other a macmice wireless mouse. i have tried other mouses but same result.
    Was wondering if anyone would know why this is doing this and mayb a fix.
    any help would be great.

    jpalan wrote:However, flash still seems to hijack everything.
    Instead of guessing, start playing mplayer and some flash source (youtube or whatever) and post the output of  'fuser -v /dev/snd/*'.
    Is your mplayer using alsa? 'cat ~/.mplayer/config' might have the answer (if you use the config) or just check mplayer output:
    ==========================================================================
    Opening audio decoder: [mpg123] MPEG 1.0/2.0/2.5 layers I, II, III
    AUDIO: 44100 Hz, 2 ch, s16le, 128.0 kbit/9.07% (ratio: 16000->176400)
    Selected audio codec: [mpg123] afm: mpg123 (MPEG 1.0/2.0/2.5 layers I, II, III)
    ==========================================================================
    AO: [alsa] 48000Hz 2ch s16le (2 bytes per sample)
    Video: no video
    Starting playback...
    See that
    AO: [alsa] 48000Hz 2ch s16le (2 bytes per sample)
    - I have configured mplayer to use alsa.

  • [SOLVED] Qemu and host-only networking

    Hi,
    I want to setup qemu with one Windows 7 guest. This guest should be able to connect to the hosts samba and postgres server, except external networks such the internet. I've read the archlinux qemu wiki page and it seems i need to use a bridge and a tap device to accomplish this. So far i've did as root:
    brctl addbr br0
    ip tuntap add dev tap0 mode tap user me
    ip link set tap0 up
    brctl addif br0 tap0
    'brctl show' gives
    bridge name bridge id STP enabled interfaces
    br0 8000.16cad3ab6bda no tap0
    When i start the vm as a user i get
    qemu-system-x86_64 -enable-kvm -m 1024 -vga std -device e1000,netdev=tap0,mac=DE:AD:BE:EF:96:32 -netdev tap,id=tap0,script=no,downscript=no hdd1.qcow2
    qemu-system-x86_64: -netdev tap,id=tap0: could not configure /dev/net/tun: Operation not permitted
    qemu-system-x86_64: -netdev tap,id=tap0: Device 'tap' could not be initialized
    Ok. Need to handle some permission issues. If i launch the above command as root, the VM (Windows 7) starts, but i don't have any connection to the host (Windows 7 complains about an unindentified network).
    With the example scripts 'qemu-ifup', 'qemu-ifdown', the ip forwarding and the sudo configuration as described in the QEMU - ArchWiki - Creating bridge manually section, Windows 7 can indeed connect to the host, but also to the internet, what i simply don't want. The reason might sound silly, but everytime a Windows guest tries to connect to the internet, thus trying to obtain an ip from the dhcp server, the host completely looses its connection to the router. It seems my network hardware doesn't like this.
    Anyway, i think i'm only missing one little thing. I would appreciate any help.
    Last edited by ulixes (2014-06-09 20:51:52)

    Thank you for this, I've tried lots of docs&tutorial, finnaly got this and success.
    ulixes wrote:
    Ok, found a solution. It's surprisingly simple. I've discarded the libvirt way, because the official archlinux virt-manager package is pretty unusable and configuring a working vlan for libvirt seems pretty complicated. I still couldn't get a working network device on the guest side.
    For completeness, here is what i've done. I use a tap and a bridge device and dnsmasq. I did not activate ipv4 forwarding like mentioned in the wiki! The following steps need to be done as root.
    First i've created the bridge, set an ip address and started it
    brctl addbr br0
    ip addr add 192.168.179.1/24 broadcast 192.168.179.255 dev br0
    ip link set br0 up
    The subnet should differ from any other device. In my case the only other device eth0 has the ip 192.168.178.xxx.
    Next i've created the tap device for use by qemu respectively the guest
    ip tuntap add dev tap0 mode tap
    ip link set tap0 up promisc on
    I don't know if 'promics' is really necessary, but there's no need to assign an ip to the tap device.
    Now i've connected the tap device to the bridge
    brctl addif br0 tap0
    Until now this was approximately my first try. I've tried to use static ip on the guest side, but had no succeess. The important point was to run dnsmasq on the bridge
    dnsmasq --interface=br0 --bind-interfaces --dhcp-range=192.168.179.10,192.168.179.254
    In effect, i finally got working ip on the guest network devices (this may take some seconds). Pinging the host succeded and neither of my guests (SliTaz Linux, Windows 7) were able to connect to external networks, thus the internet.
    I've started the guests with
    qemu-system-x86_64 -enable-kvm -m 1024 -netdev tap,id=t0,ifname=tap0,script=no,downscript=no -device e1000,netdev=t0,id=nic0 <imagefile>
    In my case, i had to omit the automated exection of scripts. This way i was also able to execute the above qemu command as an ordinary user.
    Just to finalize this description for samba:
    By adding 'br0' to 'interfaces' in smb.conf, guests were able to connect to the host samba service as usual.

  • Status clsd not unique (Selection via input help (F4) only) -COOIS

    Hi all,
    We doing upgradation 4.7E to Ecc 6.O
    In coois , When we enter system status as 'clsd' , system showing error msg
    Status clsd not unique (Selection via input help (F4) only)
    Message no. COIS054
    Why this error occurs.. how to solve this???
    looking for answers..
    Thanks in advance..

    Please read OSS note 1377678.

  • Icloud only shows devices on ios8?

    why does icloud.com only show devices signed into ios8? Does this mean someone could be running your icloud on ios7 and you wouldn't know?

    hi,
    Maybe you can try some data recovery program to search your iPhone backup files. These kinds of data recovery programs
    for example, iPhone Data Recovery, are designed to help users to find back and recover their lost files.
    I suggest that you run this kind of software, and then choose the 3rd mode in the software to retrieve all of your iCloud backup, I guess you can see your iPhone backup there.
    With such awesome software, you can also recover deleted or lost iPhone data.
    Good luck, friend.

  • When connecting ipad to iPhones personal hotspot via wifi it is showin up as 2 connections when only 1 device is connected. Is someone hacking my phone?

    When connecting ipad to my iPhones personal hotspot via wifi it is showin up as 2 connections when only 1 device is connected. Is someone hacking my phone? I only figured out I had a problem when my partner did the exact same set up and it showed up as only 1 device connected. I have changed the password and turned it off/on and etc. the really weird thing is now when my ipad is turned off and I turn my iphone personal hotspot on it shows up with 1 connection (when I don't have anything connected) for about 5 secs and then goes off and then 1 device connected for about 5 secs and then back off. This just keeps going on and off. What is going on. Could my phone have a bug or be hacked. Please help as it is kinda freaking me out. Thanks.

    Hello asrt17,
    This may occur if your iPhone is connected to your computer via USB, as it will automatically share the connection via USB.
    iOS: Troubleshooting Personal Hotspot
    http://support.apple.com/kb/TS2756
    When Personal Hotspot is enabled, your iOS device automatically shares your Internet connection with your computer when connected using USB.
    Example: When you connect iPhone to your computer to charge or sync with iTunes. To avoid unnecessary data charges, turn off Personal Hotspot when not in use.
    Cheers,
    Allen

Maybe you are looking for