Link: MySQL Best Practices

I came across this site today which has some good advice for MySQL. I’m particularly happy to see that Doctrine, a relatively new ORM for PHP which we’re big fans of, is gaining some traction.

I also noticed that Piwik, an open source analytics package, are using some interesting quality assurance tools which may be of interest to PHP developers (along with a continuous integration tool I came across recently: phpUnderControl).

Posted in Links, MySQL, PHP | Tagged , , , | Leave a comment

HTTP Streaming with Encryption under Linux

For a customer of ours, we need to mass encode thousands of video files and also segment and encrypt them for use with Apple’s HTTP Streaming. (using Amazon EC2 instances for the leg work).

On his blog, Carson McDonald, has put together a good over view of how HTTP Streaming can work under Linux a long with a segmenter.

The one piece of the jigsaw we were missing was encryption and after some work ourselves and with the help of a stackoverflow question, we have a working sequence of commands to successfully and compatibly encrypt segments for playback on Safari and other supported HTTP streaming clients:

  1. Create a key file:
    openssl rand 16 > static.key
  2. Convert the key into hex:
    key_as_hex=$(cat static.key | hexdump -e '16/1 "%02x"')
  3. At this point, let’s assume we have segmented a file of 30 seconds called video_low.ts into ten 3 second segments called video_low_X.ts where X is an integer from 1 to 10. We can then encrypt these as follows:
    for i in {0..9}; do
        init_vector=`printf '%032x' $i`
        openssl aes-128-cbc -e -in video_low_$(($i+1)).ts     \
            -out video_low_enc_$(($i+1)).ts -p -nosalt        \
            -iv $init_vector -K $key_as_hex
    done
    

With a matching m3u8 file such as the following, the above worked fine:

#EXTM3U
#EXT-X-TARGETDURATION:3
#EXT-X-MEDIA-SEQUENCE:0
#EXTINF:3,
#EXT-X-KEY:METHOD=AES-128,URI="http://www.example.com/static.key"

http://www.example.com/video_low_enc_1.ts

#EXTINF:3,

http://www.example.com/video_low_enc_2.ts

...
#EXT-X-ENDLIST

What caught us out was the initialisation vector with is described in the draft IETF document as follows:

128-bit AES requires the same 16-octet Initialization Vector (IV) to
be supplied when encrypting and decrypting. Varying this IV
increases the strength of the cipher.

If the EXT-X-KEY tag has the IV attribute, implementations MUST
use the attribute value as the IV when encrypting or decrypting
with that key. The value MUST be interpreted as a 128-bit
hexadecimal number and MUST be prefixed with 0x or 0X.

If the EXT-X-KEY tag does not have the IV attribute,
implementations MUST use the sequence number of the media
file as the IV when encrypting or decrypting that media file.
The big-endian binary representation of the sequence number
SHALL be placed in a 16-octet buffer and padded (on the left)
with zeros.

Posted in Video | Tagged , , , | 1 Comment

We’re Hiring: PHP Developer with Linux / UNIX System Admin Skills

Maybe we’re hoping for too much, but we’re looking for one person to fill one vacancy and we’re hoping that that person can provide a slightly mixed bag of skills!

Specifically, we’re currently looking for a PHP developer with Linux system administration skills and would welcome applications from anyone with (in order of preference):

  • skills and experience in both categories;
  • an experienced PHP developer with a good handle on basic Linux administration from managing their own LAMP stacks; or
  • a Linux system administrator with excellent scripting skills who would like to add PHP to their toolbox.

Please see our sneak preview post for details on what might qualify you as a junior or intermediary system administrator.

The job will entail typical Linux admin tasks and responsibilities (many of which can be learned on the job) such as:

  • administrating multiple Linux servers;
  • virtualisation with Xen;
  • management of services including Apache, MySQL, Postfix, Dovecot (POP3, IMAP), SNMP, OpenVPN, NFS, SSH, Jabber, Quagga,etc;
  • a lot of CLI scripting (mainly using languages of your choice from bash, Perl, Python, or preferably PHP);
  • backup management; and
  • assist in resolving systems outages out-of-hours.

From the PHP side of things, the following would rank you highly with us:

  • a good portfolio of PHP applications previously developed;
  • good experience with the LAMP stack;
  • fluency with OOP design and an ability to write clean elegant code with depth (usability, flexibility, stability, scalability, and maintainability);
  • use of MVC design where we use:
    • the Zend Framework (including Application and Controller);
    • the Doctrine ORM;
    • the Smarty templating engine.

A successful candidate would have or be:

  • excellent communication skills;
  • forward thinking and have good planning skills;
  • excellent troubleshooting, judgment, and decision-making skills;
  • independent worker with a high level of self-motivation and proven ability for self-study and learning on the job;
  • flexible and dependable, On-call work and Out of hours duties may be required from time to time;
  • a team player;
  • be able to understand and meet customer expectations;
  • good documentation skills.

CVs in an open document format (Open Office, RTF, HTML, PDF) can be sent to jobs (at) opensolutions (dot) ie.

Unsolicited CVs, phone calls and / or emails from recruitment agencies are not welcome.

Posted in Jobs, PR | Leave a comment

Welcome to Our New Website

Welcome to our newly designed website which we’ve worked hard on to try and bring a new fresh feel to our company’s on-line presence.

While our old site served us well (pictured below), it hadn’t received any real design updates in over three years and we thought the time had come for a fresh version. You can see the old site below (which was based on a template from Open Source Web Design).

Old Website

Open Solutions' Old Website (replaced August 2010)

We’ve also created a WordPress template for our blog so that it integrates seamlessly into the site and added feeds from the blog to the home page and the news page in the hope of keeping the on-line content fresh!

Over the coming weeks and months we hope to continue to add new content through the blog and to also update some of the static pages. We intend to do this through both in depth case studies of solutions we created as well as posts explaining some of what we do in greater detail.

Under the Hood

For those of you interested, we’ve used the following to create this site:

  • The Zend Framework for:
    • the Zend Controller;
    • the Zend Application boot strapping;
    • the Zend Logger; and
    • the Zend feed reader (to pull information from our blog).
  • Smarty, the PHP templating engine;
  • JQuery, the JavaScript library for the home page transitions and menu; and
  • Yahoo’s YUI CSS reset packages (Reset CSSBase CSS and Fonts) to ensure a consistent cross browser look.

The above may seem like overkill for a primarily static website, but as we develop many web applications on this framework it was very easy for us to create the structure around which we entered the content. We also plan to migrate some different online portals we have to this new infrastructure where upon the above framework will be essential.

The site is served from a Linux server (LAMP stack) running as a Xen unprivileged domain on one of our Dell PowerEdge R710 boxes.

We plan a case study on a web application we developed soon in which we’ll go into greater detail on the framework we use.

Posted in PR | 2 Comments

Sneak Preview: We’re Hiring!

We’ll be officially announcing this towards the latter half of next as well as publicising it on various mailing lists and job sites. In the mean time, we would welcome any early CVs.

We looking for a Junior or Intermediary Linux System Administrator. Junior doesn’t mean trainee by the way – we would consider you a junior Linux system administrator if:

  • you’ve worked as a Linux administrator for about 12 months for another company; or
  • you haven’t worked as a Linux system administrator but have got LPI / Red Hat or other certifications; or
  • at the very least you’ve used Linux on the desktop for >3 years and have had some involvement in administrating college computer society servers, community project servers, etc.

You’re intermediary if you have about two years real work experience and have:

  • a very good understanding of the LAMP stack from an administrative perspective;
  • experience and / or knowledge of some typical services such as: DNS, SMTP, POP3 / IMAP, SSH, NFS;
  • a good understanding of basic networking principals and protocols such as HTTP, POP3, SMTP sessions for debugging; TCP, UDP and ICMP protocols; IP addressing and basic LAN routing.

While we currently only have one opening, we would also consider applications from PHP developers with a good familiarity with the Linux command line and the LAMP stack. This candidate would work with us as a mixed hat PHP developer and system administrator.

By the same token, any Linux system administrator with good PHP development knowledge could leap better qualified administrators.

CVs in an open document format (Open Office, RTF, HTML, PDF) can be sent to jobs (at) opensolutions (dot) ie.

Unsolicited CVs, phone calls and / or emails from recruitment agencies are not welcome.

Posted in Jobs, PR | 2 Comments

Who We Are and What We Do

Corporate

Welcome to our new blog – a view from the inside. Over the coming months and years we hope to share different perspectives of our company with you. We’ll tell you about the company and its staff; our customers past and present; case studies of interesting projects we’ve worked on and the solutions we’ve developed; hints, tips and how-tos from our staff in all the areas we work in; and release some of the software we have worked on or maintain.

Firstly, we need to tell you who we are and what we do!

Open Solutions was formed as a business name in 2005 by myself, Barry O’Donovan. As we grew, we formalised the business in 2007 as a limited liability company. We work out of offices in Sandyford Business Park in Dublin, Ireland with customers in Ireland, the UK, the US, Switzerland, Cyprus and beyond. While we’re a small but growing company, we accomplish more in a day than our numbers would suggest.

Our motto is to work smarter, not harder. We automate repetitive tasks; we build tools and write scripts to take care of the mundane; we create robust fault tolerant networks; we design highly available and stable server farms; and we deploy intelligent and thorough monitoring systems that alert us to issues before they happen – not when they happen.

At its most basic, Open Solutions is a service and consultancy company specialising in a combination of unique areas: advanced IP networking; Linux/UNIX server farms; VoIP application programming; and web application development. By being able to leverage experience in all of these areas, we are ideally suited to provided services and solutions in the general Internet Service Provision area as well as multi-disciplinary solutions you may not have expected.

While we work closely with all our customers, some of them come to us in the product incubation stage – when they have an idea but are not sure if it’ll work or if it’s even possible – and with these we form a close partnership and can often provide a CTO role. It’s much more about what we need to do rather than what you need to do.

Our customers come from all areas of industry: INEX, Ireland’s IXP; imag!ne, one of Ireland’s largest telecommunications and broadband services provider; Showreel Player, a unique industry specific network launching in 2011; Cab Call, a new innovative location based service; and many more.

Among our staff we have some keen interests including: optimising queries and fine tuning MySQL; practical IPv6 roll out and promotion; mapping and OpenStreetMap; PHP frameworks with Zend, Doctrine and Smarty; debating the merits of JQuery vs. YUI; Asterisk programming and telephony; all forms of IP switching and routing; open source evangelism; highly available and robust solutions in networking and applications; and many more.

Bookmark us now and over the coming weeks, months and years we hope to keep your attention by bringing you all kinds of articles on the above.

Posted in PR | Tagged | Leave a comment