{"id":3627,"date":"2008-05-17T09:03:57","date_gmt":"2008-05-17T13:03:57","guid":{"rendered":"http:\/\/scruss.com\/blog\/2008\/05\/17\/how-to-fix-the-annoying-ubuntudebian-xmlsax-install-problems\/"},"modified":"2008-05-17T09:03:57","modified_gmt":"2008-05-17T13:03:57","slug":"how-to-fix-the-annoying-ubuntudebian-xmlsax-install-problems","status":"publish","type":"post","link":"https:\/\/scruss.com\/blog\/2008\/05\/17\/how-to-fix-the-annoying-ubuntudebian-xmlsax-install-problems\/","title":{"rendered":"how to fix the annoying Ubuntu\/Debian XML::SAX install problems"},"content":{"rendered":"<p>Debian and its derived distributions have a policy about packages not being able to modify the configuration of other packages. While this might generally seem like a good idea, for the <abbr title=\"There Is More Than One Way To Do It\">TIMTOWTDI<\/abbr> world of <a href=\"http:\/\/www.perl.com\/\">Perl<\/a>, this causes problems.<\/p>\n<p>The problem arises if you have installed Perl XML modules from both <a href=\"http:\/\/search.cpan.org\/\">CPAN<\/a> and the Debian (or <a href=\"http:\/\/ubuntu.com\/\">Ubuntu<\/a>, or whatever) repositories. Debian&#8217;s modifications subtly break the XML::SAX module, on which most Perl XML modules (including the brilliant <a href=\"http:\/\/search.cpan.org\/~grantm\/XML-Simple-2.18\/lib\/XML\/Simple.pm\">XML::Simple<\/a>) depend. If you&#8217;ve been naughty and used a module from CPAN, Debian gets its knickers in a knot, and won&#8217;t configure or run anything remotely related to libxml-sax-perl.<\/p>\n<p>If you get the error <strong>Can&#8217;t locate object method &#8220;save_parsers_debian&#8221; via package &#8220;XML::SAX&#8221; at \/usr\/bin\/update-perl-sax-parsers line 90<\/strong>, your system is affected. You might get the clue that any of your Perl XML handlers freak out and fail in weird ways.<\/p>\n<p>Here&#8217;s <em>a<\/em> method (there&#8217;s always more than one, of course)\u00c2\u00a0 to fix it. This was combined from a <a href=\"http:\/\/blog.aklaswad.com\/2006\/000071.html\">couple<\/a> of <a href=\"https:\/\/bugs.launchpad.net\/ubuntu\/+source\/libxml-sax-perl\/+bug\/13917\">sources<\/a>, each of which was on the right track but didn&#8217;t entirely work. Actually, <a href=\"http:\/\/blog.aklaswad.com\/2006\/000071.html\">the first might&#8217;ve been right on the money<\/a>, but my hiragana&#8217;s a bit ropey &#8230;<\/p>\n<ol>\n<li>make sure you&#8217;ve got your system up to date with <code>apt-get<\/code> or <code>aptitude<\/code>.<\/li>\n<li><code>sudo cpan CPANPLUS<\/code> (<em>this will ask you lots of questions, to which you should almost always answer with the default<\/em>)<\/li>\n<li><code>sudo cpanp -u XML::SAX<\/code> (<em>this takes quite a while, and produces no output for most of it<\/em>)<\/li>\n<li><code>LC_ALL=C sudo apt-get install --reinstall libxml-sax-perl<\/code> (<em>the <\/em><code>LC_ALL=C<\/code><em> might not be strictly necessary, but it worked for me<\/em>)<\/li>\n<\/ol>\n<p>You must remember never to pretend to be smarter than the Debian maintainers, and suitably chastened, may now return to your normal <a href=\"http:\/\/www.ubuntu.com\/usn\/usn-612-1\">OpenSSH patching<\/a> activities &#8230;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Debian and its derived distributions have a policy about packages not being able to modify the configuration of other packages. While this might generally seem like a good idea, for the TIMTOWTDI world of Perl, this causes problems. The problem arises if you have installed Perl XML modules from both CPAN and the Debian (or [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2}},"categories":[7],"tags":[176,1286,1289,187,1288,194,305,1287],"class_list":["post-3627","post","type-post","status-publish","format-standard","hentry","category-computers-suck","tag-bug","tag-debian","tag-libxml","tag-perl","tag-sax","tag-snark","tag-ubuntu","tag-xml"],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_shortlink":"https:\/\/wp.me\/pQNZZ-Wv","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/scruss.com\/blog\/wp-json\/wp\/v2\/posts\/3627","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/scruss.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/scruss.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/scruss.com\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/scruss.com\/blog\/wp-json\/wp\/v2\/comments?post=3627"}],"version-history":[{"count":0,"href":"https:\/\/scruss.com\/blog\/wp-json\/wp\/v2\/posts\/3627\/revisions"}],"wp:attachment":[{"href":"https:\/\/scruss.com\/blog\/wp-json\/wp\/v2\/media?parent=3627"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/scruss.com\/blog\/wp-json\/wp\/v2\/categories?post=3627"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/scruss.com\/blog\/wp-json\/wp\/v2\/tags?post=3627"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}