Tag Archives: mac os x

How to set the frame rate for a project in iMovie 10.4

If you use different devices to record video, you might have come across “jittery” playback of some clips: if the project has a frame rate different from the clip you’re adding, iMovie adapts by removing frames, or duplicating them, depending on whether the clip frame rate is higher or lower than the project frame rate.

So how does iMovie determine which frame rate to use for a project? It sets the project frame rate when you add the first clip to the project. However, it only does that if you click the plus icon! If you drag the clip from the media browser to the timeline, it keeps it’s default, which for me (in Europe) appears to be 24 frames per second.

Screencast showing clicking and dragging of clips in iMovie

Click + to add the first clip to set the project frame rate

Since there is no way to change the frame rate after adding the first clip, make sure you drag an appropriate clip in to the time line first thing. The only way I found to check if the correct frame rate has been set is to export the project and check with QuickTime or VLC.

OpenStack: fixing “No socketless chef-zero server”

I’ve started playing with various incarnations of “in a box” OpenStack setups to familiarize myself with OpenStack, among them DevStack and Ubuntu OpenStack. The OpenStack Chef Repo looks promising to me, as it gives you a good starting point, but can easily be extended to more complex lab setups, or even full productions environments.

The only problem? This error:

$ git clone https://github.com/openstack/openstack-chef-repo
$ export REPO_OS=centos7.1
$ cd openstack-chef-repo
$ chef exec rake berks_vendor
$ chef exec rake aio_neutron
chef exec chef-client --force-formatter -z vagrant_linux.rb aio-neutron.rb
[2015-08-09T23:41:58+02:00] INFO: Started chef-zero at chefzero://localhost:8889 with repository at /Users/stb/working/xxx/openstack-chef-repo
  One version per cookbook

[2015-08-09T23:41:58+02:00] INFO: Forking chef instance to converge...
Starting Chef Client, version 12.3.0
...
[2015-08-10T00:02:19+02:00] INFO: Converging controller because 'converge true' is set ...
[2015-08-10T00:02:19+02:00] INFO: Port forwarded: local URL chefzero://localhost:8889 is available to 127.0.0.1 as chefzero://localhost:8889 for the duration of this SSH connection.
[2015-08-10T00:02:19+02:00] INFO: Executing sudo chef-client -l info on vagrant@127.0.0.1

    [controller] [2015-08-09T22:02:18+00:00] INFO: Forking chef instance to converge...
                 Starting Chef Client, version 12.4.1
                 [2015-08-09T22:02:18+00:00] INFO: *** Chef 12.4.1 ***
                 [2015-08-09T22:02:18+00:00] INFO: Chef-client pid: 13637
                 
                 ================================================================================
                 Chef encountered an error attempting to load the node data for "controller"
                 ================================================================================
                 
                 Unexpected Error:
                 -----------------
                 ChefZero::ServerNotFound: No socketless chef-zero server on given port 8889
                 
                 
                 Running handlers:
                 [2015-08-09T22:02:20+00:00] ERROR: Running exception handlers
                 Running handlers complete
                 [2015-08-09T22:02:20+00:00] ERROR: Exception handlers complete
                 Chef Client failed. 0 resources updated in 2.194757362 seconds
                 [2015-08-09T22:02:20+00:00] FATAL: Stacktrace dumped to /var/chef/cache/chef-stacktrace.out
                 [2015-08-09T22:02:20+00:00] ERROR: No socketless chef-zero server on given port 8889
                 [2015-08-09T22:02:20+00:00] FATAL: Chef::Exceptions::ChildConvergeError: Chef run process exited unsuccessfully (exit code 1)
[2015-08-10T00:02:23+02:00] INFO: Completed chef-client -l info on vagrant@127.0.0.1: exit status 1

I’m far from an expert in Chef, so it took me a bit of searching and experimenting. Luckily, the solution is rather simple:

$ chef gem list -d '^chef-provisioning$'

*** LOCAL GEMS ***

chef-provisioning (1.1.1)
    Author: John Keiser
    Homepage: http://github.com/chef/chef-provisioning/README.md
    Installed at: /opt/chefdk/embedded/lib/ruby/gems/2.1.0

    A library for creating machines and infrastructures idempotently in
    Chef.
$ chef gem update chef-provisioning
Updating installed gems
Updating chef-provisioning
Fetching: chef-provisioning-1.3.0.gem (100%)
WARNING:  You don't have /Users/stb/.chefdk/gem/ruby/2.1.0/bin in your PATH,
	  gem executables will not run.
Successfully installed chef-provisioning-1.3.0
Gems updated: chef-provisioning
$ chef gem list -d '^chef-provisioning$'

*** LOCAL GEMS ***

chef-provisioning (1.3.0, 1.1.1)
    Author: John Keiser
    Homepage: http://github.com/chef/chef-provisioning/README.md
    Installed at (1.3.0): /Users/stb/.chefdk/gem/ruby/2.1.0
                 (1.1.1): /opt/chefdk/embedded/lib/ruby/gems/2.1.0

    A library for creating machines and infrastructures idempotently in
    Chef.

The next version of ChefDK will likely come with this updated version of chef-provisioning, but until then, this should do the trick.

Identifying and reparing broken MP3s

I only recently learned about iTunes being able to transcode music into 128kbit/s AAC on the fly, while syncing to the iPhone. Quite useful, since I’m keeping my music in 256 or 320 kbit/s MP3. Using the lower bitrate AAC on the iPhone still gives me decent quality on the go, while saving space for more music and apps.

Only one annoying problem: over the years and moving the music library from machine to machine, some files got corrupted. When I come across one during playback and I’m sufficiently annoyed by the problem, I’ll simply delete it and re-rip it, or buy a copy from the store. However, when iTunes tries to transcode all the files I want synced to my iPhone, it stumbles over files with encoding problems, and stops syncing. And the error message doesn’t even identify the file it’s having problems with, only the song title. Bummer.

iTunes does not appear to have a way to check and mark files with encoding problems, so you have to rely on identifying problematic files by playing them. Not very convenient. Luckily, I found MP3 Scan+Repair, a Mac program that will check a batch of files, identify broken ones, and even try to repair them.

You can drag files from the Finder or iTunes into MP3sar’s main window, and it will immediately start scanning them. Using the display filter buttons in the toolbar, you can show only the problematics files, select them, and let the program try and repair them. In my limited testing so far, M3SAR does a good job of identifying and repairing the files, even if some problems will only fix the file format, but not remove audible errors. But for being able to quickly see which of the twelve different versions of My Funny Valentine is stopping iTunes from syncing my iPhone is absolutely worth it.