{"id":218,"date":"2008-01-19T01:17:48","date_gmt":"2008-01-19T01:17:48","guid":{"rendered":"https:\/\/www.garfnet.org.uk\/cms\/coppermine-qbatch-addq-hangs\/"},"modified":"2024-07-18T14:48:26","modified_gmt":"2024-07-18T14:48:26","slug":"coppermine-qbatch-addq-hangs","status":"publish","type":"post","link":"https:\/\/garfnet.org.uk\/cms\/2008\/01\/19\/coppermine-qbatch-addq-hangs\/","title":{"rendered":"Coppermine &#8220;batch-add&#8221; hangs"},"content":{"rendered":"<p><strong>Just occasionally one stumbles across a small but very annoying problem, that takes ages to hunt down a fix. However, when you do stumble across the solution, you find it was just one tiny mistake &#8211; that should never have been made in the first place.<\/strong><\/p>\n<p>On our site <a href=\"http:\/\/www.garfnet.org.uk\/coppermine\" target=\"_blank\" rel=\"noopener\">http:\/\/www.garfnet.org.uk\/coppermine<\/a> we use a special Coppermine feature that allows us to add a number of files at once. It is only available to site admins but the site would be almost impossible to run with out it. The problem was that the &#8220;<em>batch add files<\/em>&#8221; button&nbsp; did not respond when we clicked it. Instead, the existing page just hung and after several minutes the browser showed a &#8220;<em>Page cannot be displayed<\/em>&#8221; error. I was really tearing my hair out. Even got my Chris Attewell, our ISP physically to reboot the machine.<\/p>\n<p>Fortunately, we use SSH (secure shell) to control our servers remotely and when I ran &#8220;<em>top<\/em>&#8221; (a Linux program that shows memory and processor usage), every time someone clicked the &#8220;<em>batch-add<\/em>&#8221; button and the &#8220;<em>searchnew.php<\/em>&#8221; script was activated, an Apache2 process snaffled 99% of the machine&#8217;s processor resources and the rest of the machines services ran at a snail&#8217;s pace. This lasted until eventually &#8220;<em>searchnew.php<\/em>&#8221; script timed out. However there were no Coppermine or MySQL\/PHP error messages and nothing unusual in either the Apache <em>access<\/em> or <em>error<\/em> logs.<\/p>\n<p>I even installed a second Coppermine with a blank dataset and no files. Initially this ran fine &#8211; whch eliminated any MySQL &amp; PHP issues &#8211; though we regularly &#8220;apt-get upgrade&#8221; for security reasons anyway. However when I copied our image files to the new installation the &#8220;batch-add&#8221; also failed &#8211; even before I had started to populate the new Coppermine database. This suggested that the problem may lie with our files and not with Coppermine.<\/p>\n<p>So I used Konquerer (part of the KDE desktop for Linux) &#8220;<em>fish<\/em>&#8221; protocol securely to browse the files on our server (much more secure than FTP). That is when I stumbled across the problem. It was caused by <em>circular symbolic links<\/em> &#8211; and frankly gross stupidity on my part for allowing the situation to occur in the first place! Let me explain&#8230;<\/p>\n<p>Unix allows you to create links to other files and folders as if they were in your current folder. In my case&#8230;<\/p>\n<ul style=\"margin-top: 0pt; margin-bottom: 0pt;\">\n<li>There was a symlink from \/var\/www\/garfnet\/<strong>coppermine<\/strong>\/<strong>albums<\/strong> to \/var\/www\/garfnet\/<strong>media<\/strong>.<\/li>\n<li>There was a second symlink from \/var\/www\/garfnet\/<strong>media<\/strong> to \/var\/www\/garfnet\/<strong>sounds<\/strong>. So far so good.<\/li>\n<li><em><strong>However<\/strong><\/em> a third link from \/var\/www\/garfnet\/<strong>sounds<\/strong> to \/var\/www\/garfnet\/<strong>coppermine<\/strong> meant that whenever the &#8220;searchnew.php&#8221; went hunting for files, it was going round in circles.&nbsp;<\/li>\n<\/ul>\n<p>Deleting that third symlink fixed the issue instantly and the system is working fine again &#8211; though I am finding it hard to come to terms with my embarrassment! Anyway, the moral of the story is that a <em>&#8220;batch-add&#8221; not responding<\/em> issue <em><strong>could<\/strong><\/em> be related to your file structure rather than to Coppermine. Or perhaps the moral is, don&#8217;t drink too much Jagermeister whilst creating symlinks.<\/p>\n<p>In any event, I hope this is of some help to someone.<\/p>\n<pre>&nbsp;<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Just occasionally one stumbles across a small but very annoying problem, that takes ages to hunt down a fix. However, when you do stumble across the solution, you find it was just one tiny mistake &#8211; that should never have been made in the first place. On our site http:\/\/www.garfnet.org.uk\/coppermine we use a special Coppermine&#8230;<\/p>\n","protected":false},"author":1,"featured_media":26717,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"ngg_post_thumbnail":0,"_kad_post_transparent":"default","_kad_post_title":"default","_kad_post_layout":"default","_kad_post_sidebar_id":"","_kad_post_content_style":"default","_kad_post_vertical_padding":"default","_kad_post_feature":"","_kad_post_feature_position":"","_kad_post_header":false,"_kad_post_footer":false,"_kad_post_classname":"","footnotes":""},"categories":[12,6,691,18],"tags":[],"class_list":["post-218","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-faq","category-journal","category-linux","category-technology"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.5 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Coppermine &quot;batch-add&quot; hangs - GarfNet<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/garfnet.org.uk\/cms\/2008\/01\/19\/coppermine-qbatch-addq-hangs\/\" \/>\n<meta property=\"og:locale\" content=\"en_GB\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Coppermine &quot;batch-add&quot; hangs - GarfNet\" \/>\n<meta property=\"og:description\" content=\"Just occasionally one stumbles across a small but very annoying problem, that takes ages to hunt down a fix. However, when you do stumble across the solution, you find it was just one tiny mistake &#8211; that should never have been made in the first place. On our site http:\/\/www.garfnet.org.uk\/coppermine we use a special Coppermine...\" \/>\n<meta property=\"og:url\" content=\"https:\/\/garfnet.org.uk\/cms\/2008\/01\/19\/coppermine-qbatch-addq-hangs\/\" \/>\n<meta property=\"og:site_name\" content=\"GarfNet\" \/>\n<meta property=\"article:published_time\" content=\"2008-01-19T01:17:48+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-07-18T14:48:26+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/garfnet.org.uk\/cms\/wp-content\/uploads\/2008\/01\/sk-alien-1024-4.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"1024\" \/>\n\t<meta property=\"og:image:height\" content=\"681\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Garf\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Garf\" \/>\n\t<meta name=\"twitter:label2\" content=\"Estimated reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"3 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/2008\\\/01\\\/19\\\/coppermine-qbatch-addq-hangs\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/2008\\\/01\\\/19\\\/coppermine-qbatch-addq-hangs\\\/\"},\"author\":{\"name\":\"Garf\",\"@id\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/#\\\/schema\\\/person\\\/27529e0ea0460ec8c299743f70c06635\"},\"headline\":\"Coppermine &#8220;batch-add&#8221; hangs\",\"datePublished\":\"2008-01-19T01:17:48+00:00\",\"dateModified\":\"2024-07-18T14:48:26+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/2008\\\/01\\\/19\\\/coppermine-qbatch-addq-hangs\\\/\"},\"wordCount\":545,\"publisher\":{\"@id\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/#\\\/schema\\\/person\\\/27529e0ea0460ec8c299743f70c06635\"},\"image\":{\"@id\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/2008\\\/01\\\/19\\\/coppermine-qbatch-addq-hangs\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/wp-content\\\/uploads\\\/2008\\\/01\\\/sk-alien-1024-4.jpg\",\"articleSection\":[\"FAQ\",\"Journal\",\"Linux\",\"Technology\"],\"inLanguage\":\"en-GB\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/2008\\\/01\\\/19\\\/coppermine-qbatch-addq-hangs\\\/\",\"url\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/2008\\\/01\\\/19\\\/coppermine-qbatch-addq-hangs\\\/\",\"name\":\"Coppermine \\\"batch-add\\\" hangs - GarfNet\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/2008\\\/01\\\/19\\\/coppermine-qbatch-addq-hangs\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/2008\\\/01\\\/19\\\/coppermine-qbatch-addq-hangs\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/wp-content\\\/uploads\\\/2008\\\/01\\\/sk-alien-1024-4.jpg\",\"datePublished\":\"2008-01-19T01:17:48+00:00\",\"dateModified\":\"2024-07-18T14:48:26+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/2008\\\/01\\\/19\\\/coppermine-qbatch-addq-hangs\\\/#breadcrumb\"},\"inLanguage\":\"en-GB\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/2008\\\/01\\\/19\\\/coppermine-qbatch-addq-hangs\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-GB\",\"@id\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/2008\\\/01\\\/19\\\/coppermine-qbatch-addq-hangs\\\/#primaryimage\",\"url\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/wp-content\\\/uploads\\\/2008\\\/01\\\/sk-alien-1024-4.jpg\",\"contentUrl\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/wp-content\\\/uploads\\\/2008\\\/01\\\/sk-alien-1024-4.jpg\",\"width\":1024,\"height\":681},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/2008\\\/01\\\/19\\\/coppermine-qbatch-addq-hangs\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Coppermine &#8220;batch-add&#8221; hangs\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/#website\",\"url\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/\",\"name\":\"GarfNet\",\"description\":\"Penguin-powered and full of Unixy goodness, since 1995...\",\"publisher\":{\"@id\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/#\\\/schema\\\/person\\\/27529e0ea0460ec8c299743f70c06635\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-GB\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/#\\\/schema\\\/person\\\/27529e0ea0460ec8c299743f70c06635\",\"name\":\"Garf\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-GB\",\"@id\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/wp-content\\\/uploads\\\/2024\\\/07\\\/garflogo-garfnet-1.png\",\"url\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/wp-content\\\/uploads\\\/2024\\\/07\\\/garflogo-garfnet-1.png\",\"contentUrl\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/wp-content\\\/uploads\\\/2024\\\/07\\\/garflogo-garfnet-1.png\",\"width\":2420,\"height\":1928,\"caption\":\"Garf\"},\"logo\":{\"@id\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/wp-content\\\/uploads\\\/2024\\\/07\\\/garflogo-garfnet-1.png\"},\"url\":\"https:\\\/\\\/garfnet.org.uk\\\/cms\\\/author\\\/garf-admin\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Coppermine \"batch-add\" hangs - GarfNet","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/garfnet.org.uk\/cms\/2008\/01\/19\/coppermine-qbatch-addq-hangs\/","og_locale":"en_GB","og_type":"article","og_title":"Coppermine \"batch-add\" hangs - GarfNet","og_description":"Just occasionally one stumbles across a small but very annoying problem, that takes ages to hunt down a fix. However, when you do stumble across the solution, you find it was just one tiny mistake &#8211; that should never have been made in the first place. On our site http:\/\/www.garfnet.org.uk\/coppermine we use a special Coppermine...","og_url":"https:\/\/garfnet.org.uk\/cms\/2008\/01\/19\/coppermine-qbatch-addq-hangs\/","og_site_name":"GarfNet","article_published_time":"2008-01-19T01:17:48+00:00","article_modified_time":"2024-07-18T14:48:26+00:00","og_image":[{"width":1024,"height":681,"url":"https:\/\/garfnet.org.uk\/cms\/wp-content\/uploads\/2008\/01\/sk-alien-1024-4.jpg","type":"image\/jpeg"}],"author":"Garf","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Garf","Estimated reading time":"3 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/garfnet.org.uk\/cms\/2008\/01\/19\/coppermine-qbatch-addq-hangs\/#article","isPartOf":{"@id":"https:\/\/garfnet.org.uk\/cms\/2008\/01\/19\/coppermine-qbatch-addq-hangs\/"},"author":{"name":"Garf","@id":"https:\/\/garfnet.org.uk\/cms\/#\/schema\/person\/27529e0ea0460ec8c299743f70c06635"},"headline":"Coppermine &#8220;batch-add&#8221; hangs","datePublished":"2008-01-19T01:17:48+00:00","dateModified":"2024-07-18T14:48:26+00:00","mainEntityOfPage":{"@id":"https:\/\/garfnet.org.uk\/cms\/2008\/01\/19\/coppermine-qbatch-addq-hangs\/"},"wordCount":545,"publisher":{"@id":"https:\/\/garfnet.org.uk\/cms\/#\/schema\/person\/27529e0ea0460ec8c299743f70c06635"},"image":{"@id":"https:\/\/garfnet.org.uk\/cms\/2008\/01\/19\/coppermine-qbatch-addq-hangs\/#primaryimage"},"thumbnailUrl":"https:\/\/garfnet.org.uk\/cms\/wp-content\/uploads\/2008\/01\/sk-alien-1024-4.jpg","articleSection":["FAQ","Journal","Linux","Technology"],"inLanguage":"en-GB"},{"@type":"WebPage","@id":"https:\/\/garfnet.org.uk\/cms\/2008\/01\/19\/coppermine-qbatch-addq-hangs\/","url":"https:\/\/garfnet.org.uk\/cms\/2008\/01\/19\/coppermine-qbatch-addq-hangs\/","name":"Coppermine \"batch-add\" hangs - GarfNet","isPartOf":{"@id":"https:\/\/garfnet.org.uk\/cms\/#website"},"primaryImageOfPage":{"@id":"https:\/\/garfnet.org.uk\/cms\/2008\/01\/19\/coppermine-qbatch-addq-hangs\/#primaryimage"},"image":{"@id":"https:\/\/garfnet.org.uk\/cms\/2008\/01\/19\/coppermine-qbatch-addq-hangs\/#primaryimage"},"thumbnailUrl":"https:\/\/garfnet.org.uk\/cms\/wp-content\/uploads\/2008\/01\/sk-alien-1024-4.jpg","datePublished":"2008-01-19T01:17:48+00:00","dateModified":"2024-07-18T14:48:26+00:00","breadcrumb":{"@id":"https:\/\/garfnet.org.uk\/cms\/2008\/01\/19\/coppermine-qbatch-addq-hangs\/#breadcrumb"},"inLanguage":"en-GB","potentialAction":[{"@type":"ReadAction","target":["https:\/\/garfnet.org.uk\/cms\/2008\/01\/19\/coppermine-qbatch-addq-hangs\/"]}]},{"@type":"ImageObject","inLanguage":"en-GB","@id":"https:\/\/garfnet.org.uk\/cms\/2008\/01\/19\/coppermine-qbatch-addq-hangs\/#primaryimage","url":"https:\/\/garfnet.org.uk\/cms\/wp-content\/uploads\/2008\/01\/sk-alien-1024-4.jpg","contentUrl":"https:\/\/garfnet.org.uk\/cms\/wp-content\/uploads\/2008\/01\/sk-alien-1024-4.jpg","width":1024,"height":681},{"@type":"BreadcrumbList","@id":"https:\/\/garfnet.org.uk\/cms\/2008\/01\/19\/coppermine-qbatch-addq-hangs\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/garfnet.org.uk\/cms\/"},{"@type":"ListItem","position":2,"name":"Coppermine &#8220;batch-add&#8221; hangs"}]},{"@type":"WebSite","@id":"https:\/\/garfnet.org.uk\/cms\/#website","url":"https:\/\/garfnet.org.uk\/cms\/","name":"GarfNet","description":"Penguin-powered and full of Unixy goodness, since 1995...","publisher":{"@id":"https:\/\/garfnet.org.uk\/cms\/#\/schema\/person\/27529e0ea0460ec8c299743f70c06635"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/garfnet.org.uk\/cms\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-GB"},{"@type":["Person","Organization"],"@id":"https:\/\/garfnet.org.uk\/cms\/#\/schema\/person\/27529e0ea0460ec8c299743f70c06635","name":"Garf","image":{"@type":"ImageObject","inLanguage":"en-GB","@id":"https:\/\/garfnet.org.uk\/cms\/wp-content\/uploads\/2024\/07\/garflogo-garfnet-1.png","url":"https:\/\/garfnet.org.uk\/cms\/wp-content\/uploads\/2024\/07\/garflogo-garfnet-1.png","contentUrl":"https:\/\/garfnet.org.uk\/cms\/wp-content\/uploads\/2024\/07\/garflogo-garfnet-1.png","width":2420,"height":1928,"caption":"Garf"},"logo":{"@id":"https:\/\/garfnet.org.uk\/cms\/wp-content\/uploads\/2024\/07\/garflogo-garfnet-1.png"},"url":"https:\/\/garfnet.org.uk\/cms\/author\/garf-admin\/"}]}},"_links":{"self":[{"href":"https:\/\/garfnet.org.uk\/cms\/wp-json\/wp\/v2\/posts\/218","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/garfnet.org.uk\/cms\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/garfnet.org.uk\/cms\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/garfnet.org.uk\/cms\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/garfnet.org.uk\/cms\/wp-json\/wp\/v2\/comments?post=218"}],"version-history":[{"count":2,"href":"https:\/\/garfnet.org.uk\/cms\/wp-json\/wp\/v2\/posts\/218\/revisions"}],"predecessor-version":[{"id":26301,"href":"https:\/\/garfnet.org.uk\/cms\/wp-json\/wp\/v2\/posts\/218\/revisions\/26301"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/garfnet.org.uk\/cms\/wp-json\/wp\/v2\/media\/26717"}],"wp:attachment":[{"href":"https:\/\/garfnet.org.uk\/cms\/wp-json\/wp\/v2\/media?parent=218"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/garfnet.org.uk\/cms\/wp-json\/wp\/v2\/categories?post=218"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/garfnet.org.uk\/cms\/wp-json\/wp\/v2\/tags?post=218"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}