xapi-project / vagrant-xenserver

A Vagrant provider for XenServer
MIT License
118 stars 29 forks source link

md5sum, bs problems on OS X #11

Open djs55 opened 9 years ago

djs55 commented 9 years ago
Davids-MacBook-Pro:v djs$ vagrant up --provider=xenserver
Bringing machine 'default' up with 'xenserver' provider...
sh: md5sum: command not found
dd: bs: illegal numeric value
vivekjuneja commented 8 years ago

Get the md5sum package for OSX using brew :

brew install md5sum

Change the bs=1M to bs=1m in the <PROJECT_HOME>/lib/vagrant-xenserver/action/upload_vhd.rb

This should help !

calebshay commented 8 years ago

I'm too busy to make a pull request right now, but upload_vhd.rb could be made cross platform with

require "digest/md5"
md5=File.open(box_vhd_file) do |fh| Digest::MD5.hexdigest(fh.read(1024*1024)) end
MichaelKraft commented 8 years ago

Thanks @vivekjuneja, your tips got me through those bits, running on OS X. I can see the VHD of the machine has been uploaded to my XenServer but then it dies with more uploader errors. This seems to be where it dies:

DEBUG subprocess: Selecting on IO
DEBUG subprocess: stderr:   % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
  0 40.0G    0     0    0     0      0      0 --:--:--  0:00:01 --:--:--     0

 INFO interface: detail: Progress: 0% (Rate: 0/s, Estimated time remaining: --:--:--)
 INFO interface: detail:     default: Progress: 0% (Rate: 0/s, Estimated time remaining: --:--:--)
  0 40.0G    0     0    0     0      0      0 --:--:--  0:00:02 --:--:--     0 subprocess: stderr: 

 INFO interface: detail: Progress: 0% (Rate: 0/s, Estimated time remaining: --:--:--)
 INFO interface: detail:     default: Progress: 0% (Rate: 0/s, Estimated time remaining: --:--:--)
    default: Progress: 0% (Rate: 0/s, Estimated time remaining: --:--:--)DEBUG subprocess: stderr: curl: (55) SSL_write() returned SYSCALL, errno = 32
DEBUG subprocess: Waiting for process to exit. Remaining to timeout: 31998
DEBUG subprocess: Exit status: 55
 WARN uploader: Uploader exit code: 55

Full log attached below. Any ideas?

fulllog.txt

vivekjuneja commented 8 years ago

@MichaelKraft , can you share the version details for cURL and OpenSSL on your OSX machine.

I will attempt to replicate this issue with the right version of the tooling.

MichaelKraft commented 8 years ago

@vivekjuneja Sorry for the delay, busy weekend. :) Versions follow:

curl 7.43.0 (x86_64-apple-darwin15.0) libcurl/7.43.0 SecureTransport zlib/1.2.5
Protocols: dict file ftp ftps gopher http https imap imaps ldap ldaps pop3 pop3s rtsp smb smbs smtp smtps telnet tftp 
Features: AsynchDNS IPv6 Largefile GSS-API Kerberos SPNEGO NTLM NTLM_WB SSL libz UnixSockets 
OpenSSL 0.9.8zh 14 Jan 2016