tag:blogger.com,1999:blog-64352666171734872532024-02-21T08:25:57.494+05:30Busy work - Just for funseth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.comBlogger199125tag:blogger.com,1999:blog-6435266617173487253.post-50071513617676564572018-11-06T13:49:00.000+05:302018-11-06T13:49:39.311+05:30Redhat Sale Evokes Painful Memories<div dir="ltr" style="text-align: left;" trbidi="on">
It has been a dozen years since I got a diskless lab created for an engineering college, with a Linux server, of course. It was not just to save money as we used the surplus to set up a multi-media lab of Macs.<br />
<br />
The result was a depressing failure. I have consistently had problems with bosses. I can't sell an idea to even my wife much less to anyone else :) Actually, doubts make me doubt myself. I have no real idea of what the future will be! And I have been "<a href="https://www.youtube.com/watch?v=7rXhXLsNJL8" target="_blank">that way since 1956</a>"<br />
<br />
Within a year, I was no longer handling the department. The new head added disks to the diskless workstations. The Linux server continued to work but only as a mail server. The reason was the future prospects for the students. The market is for Windows. Who needs open source engineers. And, of course, the Macs were not allowed to be used for exploring multi-media as that was not a part of the syllabus.<br />
<br />
All this came back to me with the news of <a href="https://arstechnica.com/information-technology/2018/10/ibm-buys-red-hat-with-eye-on-cloud-dominance/" target="_blank">IBM buying Redhat for more money than I can imagine</a>.<br />
<br />
I need to see <a href="https://en.wikipedia.org/wiki/It's_a_Wonderful_Life" target="_blank">A Wonderful Life </a>again, may be many many times :)</div>
seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com0tag:blogger.com,1999:blog-6435266617173487253.post-90309636992938629742015-01-02T13:48:00.000+05:302015-02-07T13:59:09.349+05:30Frustrating Experience with BSNL 3G Data SIM - and a workaround<div dir="ltr" style="text-align: left;" trbidi="on">
I took a BSNL SIM while travelling expecting that their services were more likely to be available in most states. Unfortunately, I did not test it well in Chandigarh before leaving.<br />
<br />
I was using a Huawei 3G E8231 dongle and it just did not connect. I tried on cell phone as well but the data connection did not happen whether 2G or 3G.<br />
<br />
I needed BSNL connection in Rajasthan where Tata Docomo did not have their own data service. Once I reached Pune, I did not need the BSNL connection but it worked using the APN bsnllive!<br />
<br />
However, my relief was not long. It did not connect in Goa either, except for some reason for 1 day, when it worked very well for the whole day and using the APN bsnlnet as expected. <br />
<br />
Since then again no connection. It is frustrating to contact BSNL support on their call centre, especially while roaming. <br />
<br />
I sent emails to the addresses mentioned on BSNL site. The messages did not bounce; however, I got no feedback at all. Curiously, the email addresses were on gmail.com :)<br />
<br />
I got a call yesterday (may be because I had visited the BSNL office in Mapusa who said that they will contact Chandigarh for help). I was told that I should try now as the problem is resolved.<br />
<br />
However, no change in status and I cannot call back the person who had called :(<br />
<br />
Finally, I got a person on 1503 of the Maharashtra circle who gave me the help number for Punjab. The person from the Punjab circle wasn't helpful at all and probably disconnected in the middle. I tried once again and it got disconnected again. No point in making any more effort.<br />
<br />
I am bewildered by why did it work on two days and not on other days. Since it worked twice, it does not seem like a compatibility problem with my devices. Oh, well, fortunately, there are many more options now, which work AND who really do try to help!<br />
<br />
I will dump the sim. A lesson learnt for a thousand rupees - a mere US$ 15 :)<br />
<br />
Update 7th Feb 2015:<br />
<br />
There had to be a reason why the BSNL connection worked twice. I kept thinking about the sequence of operations which might have been the reason.<br />
<br />
I think I now know.<br />
<br />
The default APN for bsnl is 'bsnlnet'. It did not work.<br />
I changed the profile to 'bsnllive'.<br />
Waited for a while.<br />
State is now connected. Some data is sent but nothing is received.<br />
I changed the profile back to 'bsnlnet'.<br />
State remains connected and the 3G data connection works :)<br />
<br />
The above steps have worked on two days now. <br />
Why? That remains a mystery! <br />
<br />
<br />
<br />
<br />
<br /></div>
seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com0tag:blogger.com,1999:blog-6435266617173487253.post-61498713713208458962014-11-10T14:41:00.001+05:302014-11-10T14:41:14.438+05:30OpenStack Nova Compute Cannot Launch Instance after Upgrade to Fedora 21<div dir="ltr" style="text-align: left;" trbidi="on">
I updated my system to Fedora 21 beta and then found that I could not use OpenStack. Every effort to launch an instance failed:<br />
<blockquote class="tr_bq">
libvirtError: operation failed: filter 'nova-no-nd-reflection' already exists with uuid 728f13cf-f1a9-4e0e-add7-357b93d052ee</blockquote>
Removing the openstack packages, clearing the data and reinstalling openstack did not help.<br />
<br />
The problem seems to be an incompatibility between nova-compute and the libvirt libraries.<br />
<br />
Upgrading the libvirt libraries to rawhide did not help.<br />
<br />
Finally, I used rpm to downgrade libvirt using downloaded packages from the fedora 20 repository, ignoring the dependency problems.<br />
<blockquote class="tr_bq">
$ sudo rpm -U --oldpackage --nodeps libvirt*1.1.3*rpm</blockquote>
All seems well for now. <br />
<br />
<br />
<br /></div>
seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com0tag:blogger.com,1999:blog-6435266617173487253.post-27848773501548354432014-11-03T10:52:00.002+05:302014-11-03T10:55:57.135+05:30Openstack Nova Compute fails to start after updating to 2014.1.3-2.fc21<div dir="ltr" style="text-align: left;" trbidi="on">
OpenStack nova compute service failed to start after the update to th e openstack-icehouse version 2014.1.3-2.fc21 - the reason appeared to be:<br />
<br />
<blockquote class="tr_bq">
"Failed to add interface: can't add lo to bridge br100: Invalid argument"</blockquote>
<br />
<a href="https://bugs.launchpad.net/nova/+bug/1376596">This bug report</a>, though marked as invalid, helped, The problem was a change in the file nova/network/linux_net.py. <br />
<br />
The following exception had been in the wrong place earlier and was being ignored:<br />
<blockquote class="tr_bq">
if (err and err != "device %s is already a member of a bridge; "<br />
"can't enslave it to bridge %s.\n" % (interface, bridge)):<br />
msg = _('Failed to add interface: %s') % err<br />
raise exception.NovaException(msg)</blockquote>
<br />
The interface for the flat network is set to 'lo' even if the nova.conf file does not define it. network['bridge_interface'] seems to be set to 'lo' in the following line:<br />
<br />
<blockquote class="tr_bq">
iface = CONF.flat_interface or network['bridge_interface']</blockquote>
<br />
One workaround was to change the following line in ensure_bridge method:<br />
< if interface:<br />
---<br />
> if interface and interface != 'lo':<br />
<br />
Subsequently, I came across <a href="https://bugzilla.redhat.com/show_bug.cgi?format=multiple&id=1153079">another workaround in a bug report</a> by creating a dummy interface.<br />
<br />
The virtual machines were stuck in 'powering on' state after the update. <a href="http://sethanil.blogspot.in/2014/08/openstack-virtual-machine-stuck-in-task.html">This time solving it was easy</a>!</div>
seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com1tag:blogger.com,1999:blog-6435266617173487253.post-45759662885375821132014-09-23T12:02:00.000+05:302014-09-23T12:04:03.139+05:30Experimenting with open source big data applications on a personal desktop<div dir="ltr" style="text-align: left;" trbidi="on">
I decided to learn<a href="http://sethanil.blogspot.in/2014/08/openstack-virtual-machine-stuck-in-task.html"> OpenStack</a>, Hadoop, Elasticsearch and related open source software products using my quad core desktop. I had to raise the RAM to 16GB and add a 1 terabyte disk.<br />
<br />
However, after the hardware upgrade, it has been remarkably simple to experiment and learn these tools using Fedora 20 repositories.<br />
<br />
I am writing about my experiences in a monthly column in <a href="http://www.opensourceforu.com/">Open Source for You</a> and will continue to post them on <a href="http://start.sethanil.com/bigdata">my site</a> after a month or more of the publication.<br />
<br />
I hope learning new tools is <a href="http://bigthink.com/ideafeed/learning-a-new-language-later-in-life-helps-keep-your-brain-healthy">as effective as learning new languages to keep senility away</a> after retirement :)<br />
<br /></div>
seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com0tag:blogger.com,1999:blog-6435266617173487253.post-32491277103394224952014-08-23T14:03:00.002+05:302014-08-23T14:03:50.049+05:30Csound and x86_64 machines<div dir="ltr" style="text-align: left;" trbidi="on">
I could not understand why <a href="http://sugarlabs.org/" target="_blank">Sugar</a> <a href="http://wiki.sugarlabs.org/go/Activities/TamTam" target="_blank">TamTam</a> activities wouldn't play any sound on x86_64 <a href="http://sethanil.blogspot.in/2014/06/running-tamtam-activities-on-fedora-20.html" target="_blank">even though the problem seemed resolved</a>! It took a while to realize that the problem was with x86_64 architecture. I could get the sound to play on an i686 virtual machine.<br />
<br />
Thanks to <a href="http://www.csounds.com/journal/issue14/realtimeCsoundPython.html">realtime Csound programming using Python</a>, I could trace the fault. The issue is illustrated by the following code in <a href="http://www.csounds.com/journal/issue14/realtimeCsoundPython/csoundSession.py">csoundSession.py</a>:<br />
<br />
<blockquote class="tr_bq">
<pre> if csnd.csoundGetSizeOfMYFLT() == 8:
pfields = csnd.doubleArray(n)
else:
pfields = csnd.floatArray(n)</pre>
</blockquote>
The csound client code in Python and C used by tamtam activities assumes a float array.<br />
<br />
The following line in csound.spec from rpm source makes the issue pretty clear:<br />
<br />
<blockquote class="tr_bq">
# Csound is really dumb about 64-bit</blockquote>
Rebuilding csound on x86_64 with "%define useDouble 0" even for x86_64 resolved the problem with TamTam activities.<br />
<br />
However, it is entirely possible that this workaround may cause some other applications which use csound to fail on x86_64. </div>
seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com0tag:blogger.com,1999:blog-6435266617173487253.post-68544357809523684172014-08-13T12:39:00.001+05:302014-11-18T13:13:03.836+05:30OpenStack - Virtual Machine stuck in task state 'powering-on'<div dir="ltr" style="text-align: left;" trbidi="on">
Today for the second time I had to search for the solution in <a href="http://dachary.org/?p=2939">http://dachary.org/?p=2939</a>. Last time, I seemed to have selected the right keywords but it took much more effort today. <br />
<br />
I just needed to reset task_state in instances table of the nova database:<br />
<blockquote class="tr_bq">
<pre><span style="font-family: inherit;"><span style="font-size: small;">mysql -e "update instances set task_state = NULL \
where deleted = 0 and hostname = 'master'" nova</span></span></pre>
</blockquote>
The problem may be caused by error in nova compute starting up as I use virtual machine manager as well.<br />
<br />
Virtual machine manager creates images in /var/lib/libvirt/images which are readable by root only.<br />
<br />
For some reason, nova-compute looks in this directory as well and gets errors like: <br />
<blockquote class="tr_bq">
Stderr: "qemu-img: Could not open '/var/lib/libvirt/images/fedora20.qcow2': Permission denied\n"</blockquote>
I manually change the permissions to readable by all to overcome the problem. <br />
<br /></div>
seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com0tag:blogger.com,1999:blog-6435266617173487253.post-46215012879520200412014-06-15T11:41:00.000+05:302014-06-15T11:41:09.251+05:30Running TamTam Activities on Fedora 20<div dir="ltr" style="text-align: left;" trbidi="on">
While preparing an old machine to give to the children of our helper, I had to struggle a bit to get <a href="http://wiki.sugarlabs.org/go/Activities/TamTam" target="_blank">TamTam activities</a> to run. I was using the Sugar environment on Fedora 20. The version of TamTam activities in the Fedora repository was old and did not work.<br />
<br />
The solutions were as follows:<br />
<ul style="text-align: left;">
<li>The tamtamorc.cfd file in tamtam/common/Resources/ needs an additional comma in line 62:<br /><br />$ diff tamtamorc.csd tamtamorc.csd.orig <br />62c62<br />< aindex, atrans, ifreq, iphase, itable, itabdur xin<br />---<br />> aindex, atrans, ifreq, iphase itable, itabdur xin<br /></li>
<li>On the x86_64 systems, in common/Util/Clooper, I needed to run make to make sure that aclient.so is built for the installed version of csound.</li>
</ul>
</div>
seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com0tag:blogger.com,1999:blog-6435266617173487253.post-43454164738145714432014-02-05T08:53:00.000+05:302014-02-05T08:53:17.519+05:30Getting started with Erlang Webmachine on Fedora 20<div dir="ltr" style="text-align: left;" trbidi="on">
The problems I am encountering in learning erlang on Fedora 20 is helping me understand erlang better :)<br />
<br />
I had to install erlang-ibrowse and erlang-meck even for starting the skeleton application. They should probably be included in the dependencies of erlang-webmachine rpm.<br />
<br />
The template for creating the skeleton application is included in <br />/usr/lib64/erlang/lib/webmachine-1.10.1/priv/templates.<br />
<br />
To create a new skeleton app:<br />
$ cd /usr/lib64/erlang/lib/webmachine-1.10.1/priv<br />
$ rebar create template=wmskel prefix=<path> appid=<appid><br /></appid></path><br />
$ cd <path></path><br />
$ rebar compile<br />
<br />
The wmskel.template needed to be modified to comment out the following lines related to rebar:<br />
%{file, "{{webmachine}}/rebar", "{{prefix}}/rebar"}.<br />%{chmod, 8#744, "{{prefix}}/rebar"}.<br />
<br />
The version number in rebar.config also needed to be changed from 1.9.* to 1.10.*<br />
<br />
However, execution of start.sh fails with the error:<br />
init terminating in do_boot ()<br />
<br />
The issue was that in <appid>.erl, the following statement fails:</appid><br />
ensure_started(mochiweb),<br />
<br />
It appears that some of the dependencies of mochiweb are not implicitly started. I am not sure if I am missing something, this is a fedora specific issue or a current mochiweb version issue. A work around was to modify the start function in src/<appid>.erl adding the lines in bold:</appid><br />
<br />
start() -><br /> ensure_started(inets),<br /> ensure_started(crypto),<br /><b> ensure_started(asn1),<br /> ensure_started(public_key),<br /> ensure_started(ssl),<br /> ensure_started(xmerl),<br /> ensure_started(compiler),<br /> ensure_started(syntax_tools),</b><br /> ensure_started(mochiweb),<br /> application:set_env(webmachine, webmachine_logger_module,<br /> webmachine_logger),<br /> ensure_started(webmachine),<br /> application:start(webmachine_demo).<br />
<br />
For diagnosing, modifying ensure_started function in the same file helped.<br />
<br />
ensure_started(App) -><br /> case application:start(App) of<br /> ok -><br /> ok;<br /> {error, {already_started, App}} -><br />
ok;<br /> <b>X -> io:format("App failed ~w ~w~n",[App, X])</b><br /> end.<br /><br />
<br />
Now,<br />
$ rebar compile<br />
$ ./start.sh<br />
<br />
<br />
<br />
http://localhost:8000 should show "Hello, new world".<br />
<br />
It may be preferable to modify the start function in templates/src/wmskel.erl.</div>
seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com0tag:blogger.com,1999:blog-6435266617173487253.post-45072249238519746562014-01-16T02:58:00.000+05:302014-01-16T02:58:43.571+05:30Getting started with Erlang Mochiweb on Fedora 20<div dir="ltr" style="text-align: left;" trbidi="on">
It is simple to use this<a href="http://alexmarandon.com/articles/mochiweb_tutorial/" target="_blank"> tutorial</a> for creating a minimal Erlang Mochiweb application. Clone the git repository and run make twice.<br />
<br />
However, trying to do the same on Fedora 20 using the packages erlang-mochiweb and erlang-rebar wasn't so simple.<br />
<br />
While the templates are included in the /usr/lib64/erlang/lib/mochiweb-2.4.2/support directory, it is missing the Makefile. We need to execute the rebar commands instead.<br />
<br />
Several lines need to be commented in support/templates/mochiwebapp.template. These correspond to files not included in the erlang-mochiweb rpm package -<br />
<blockquote class="tr_bq">
%%{file, "../../.gitignore", "{{dest}}/.gitignore"}.<br />%%{file, "../../Makefile", "{{dest}}/Makefile"}.<br />%%{file, "../../rebar", "{{dest}}/rebar"}.<br />%%{chmod, 8#755, "{{dest}}/rebar"}.</blockquote>
The script start-dev.sh fails. Solution is to replace '\\' by '\'. The script becomes:<br />
<blockquote class="tr_bq">
exec erl -pa ebin edit deps/*/ebin -boot start_sasl \<br /> -sname {{appid}}_dev \<br /> -s {{appid}} \<br /> -s reloader</blockquote>
Now,<br />
$ cd /usr/lib64/erlang/lib/mochiweb- 2.4.2/<br />
$ rebar create template=mochiwebapp dest=<app_dir> appid=<appid></appid></app_dir><br />
$ cd <app_dir></app_dir><br />
$ rebar compile<br />
$ ./start-dev.sh<br />
<br />
If successful, browsing localhost:8080 shows the success page.<br />
<ol style="text-align: left;">
</ol>
</div>
seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com0tag:blogger.com,1999:blog-6435266617173487253.post-50781219604475429122013-06-28T11:31:00.002+05:302013-06-28T11:40:04.032+05:30Relying more on Desktop Client for Emails<div dir="ltr" style="text-align: left;" trbidi="on">
After switching to <a href="http://sethanil.blogspot.in/2013/06/life-after-google-reader-akregator.html" target="_blank">Akregator from Google Reader</a> and learning to live with a little inconvenience, I was struck by a comment about the danger of email accounts being broken into by the criminal elements.<br />
<br />
I now have setup an imap account and am using Kmail. Contents of any folder/label which need not available for easy access online, I plan to move to a local folder. I will miss out on the power of Google search, but I think, along with consuming less energy, learning to live with some technological inconveniences is the preferred/imperative option.<br />
<br />
Update - Came across an interesting news of excessive reliance of technology - <a href="http://news.cnet.com/8301-17852_3-57591449-71/when-technology-fails-a-news-anchor-there-are-no-words/" target="_blank">When technology fails a news anchor, there are no words</a>.<br />
<br />
<br /></div>
seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com0tag:blogger.com,1999:blog-6435266617173487253.post-61457170994898626752013-06-20T12:52:00.001+05:302013-06-20T12:52:34.380+05:30Life after Google Reader - Akregator<div dir="ltr" style="text-align: left;" trbidi="on">
Web based services are convenient. It is far too easy to get used to them. I tend to look at my rss feeds from at least two systems. So, it seemed that I will use one of the online services which are trying to replace Google Reader and make the transition as painless as possible.<br />
<br />
In view of the recent <a href="http://www.guardian.co.uk/world/2013/jun/06/us-tech-giants-nsa-data" target="_blank">disclosures about Prism</a>, opting for a little inconvenience is not a bad idea.<br />
<br />
I am now quite comfortable with Akregator. One advantage is that I can see and access the entries I have already read as well. The responsiveness is very good.<br />
<br />
To switch between machines, I take a tar backup of .kde/share/apps/akregator from one machine and restore it on the other. Since it is a bit of a nuisance, I am organizing my net activities to normally use one system only for reading rss feeds and switch rarely.<br />
<br />
It is not a very serious constraint and probable saves me distractions.<br />
<br />
The mail services of our ISP are very unreliable otherwise I might have seriously considered at least partially moving from gmail.<br />
<br />
As long as software read the content, I was unaffected; hence, no impact of Microsoft's criticisms of Google. This is probably more common than just for me as <a href="http://www.cs.nott.ac.uk/~gxk/courses/g5aiai/002history/eliza.htm" target="_blank">stories</a> about <a href="http://en.wikipedia.org/wiki/ELIZA" target="_blank">Eliza</a> illustrate -<br />
<blockquote class="tr_bq">
Another story tells of the author's secretary using Eliza when he entered the
room. The secretary asked her boss to leave until she had finished her conversation. </blockquote>
<blockquote class="tr_bq">
The author also considered putting in a module that recorded peoples conversations.
This was greeted with accusations that Weizenbaum was spying on their secrets
and innermost thoughts.</blockquote>
So, humans reading our content is another issue! <br />
<br />
<a href="http://en.wikipedia.org/wiki/Foundation_series" target="_blank">Robots, however, guide and save humanity</a> :)</div>
seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com0tag:blogger.com,1999:blog-6435266617173487253.post-68461705713126433232013-06-20T12:07:00.002+05:302013-06-20T12:07:39.819+05:30Inactive logical volume after upgrading to Fedora 19<div dir="ltr" style="text-align: left;" trbidi="on">
I upgraded my netbook to Fedora 19 beta version <a href="https://fedoraproject.org/wiki/Upgrading_Fedora_using_yum" target="_blank">using yum</a>. The process was smooth and went through without a hitch.<br />
<br />
The problem came up on rebooting. Systemd waited and finally failed to mount home, which was a logical volume. This seemed strange as root and swap were also on the same volume group and were being used.<br />
<br />
Finally, lvscan showed that the home logical volume was inactive. The command<br />
<blockquote class="tr_bq">
lvchange --activate y <logical volume=""><br /></logical></blockquote>
worked and it was a relief to realize that the home logical partition was perfectly fine.<br />
<br />
Unfortunately, rebooting the system showed the same problem. The cause of the problem was that all the lvm2 services were disabled.<br />
<br />
Enabling lvm2-monitor.service resolved the issue :)</div>
seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com0tag:blogger.com,1999:blog-6435266617173487253.post-82785456860000204042013-04-12T12:22:00.000+05:302013-04-12T12:22:29.260+05:30NFS root unexpectedly squashed <div dir="ltr" style="text-align: left;" trbidi="on">
While experimenting with setting up ltsp on Fedora 18, I came across a strange NFS behaviour which took quite some time to iron out.<br />
<br />
I was already exporting /opt as a read only file system; however, with root squashed. LTSP added another export for /opt/ltsp with no_root_squash option. <br />
<blockquote class="tr_bq">
<pre class="bz_comment_text" id="comment_text_0">/opt *(ro,sync,no_subtree_check)
# export for LTSP version 5
/opt/ltsp *(ro,no_root_squash,async,no_subtree_check)</pre>
</blockquote>
<br />
Everything seemed to be sort of working with a few strange effects, e.g. I could not use passwords and some ltsp scripts were failing. <br />
The problem was that root seemed to be still squashed:<br />
<blockquote class="tr_bq">
<pre class="bz_comment_text" id="comment_text_0">[anil@localhost ~]$ sudo mount amd:/opt/ltsp/x86_64 /mnt
[anil@localhost ~]$ cd /mnt/home
[anil@localhost home]$ ls -l
total 8
drwxrwx--- 2 anil anil 4096 Apr 6 13:04 anil
drwx------ 2 guest guest 4096 Apr 10 12:35 guest
[anil@localhost home]$ sudo su
[root@localhost home]# cd anil
bash: cd: anil: Permission denied</pre>
</blockquote>
A workaround was to use fsid=0 although whatever documentation I came across seemed to suggest that it was no longer needed: <br />
<blockquote class="tr_bq">
<pre class="bz_comment_text" id="comment_text_0">/opt/ltsp *(ro,fsid=0,no_root_squash,sync,no_subtree_check)</pre>
</blockquote>
Unfortunately, I had forgotten that /opt was also being exported and noticed it only after finding the work-around and getting ltsp to work on Fedora 18.</div>
seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com0tag:blogger.com,1999:blog-6435266617173487253.post-80629067889278063122013-03-31T14:14:00.001+05:302013-03-31T14:14:28.206+05:30Arch Linux installation using ipxe and a Fedora server<div dir="ltr" style="text-align: left;" trbidi="on">
Arch Linux is great way to learn, e.g. <a href="http://releng.archlinux.org/pxeboot/" target="_blank">installing Arch Linux booting over the network</a>. As is usual with Arch Linux, the documentation for the process is excellent. Surprisingly, a mirror in India gave an excellent speed and low latency so even the first stage went well.<br />
<br />
Since I was experimenting with ipxe, I decided to install<a href="https://wiki.archlinux.org/index.php/PXE" target="_blank"> Arch Linux using the iso and ipxe</a>. Using dnsmasq was no problem. However, since I use Fedora and the default is dhcpd, I wanted to make it work with dhcpd. The problem was finding the equivalent options of dhcp-option-force.<br />
<br />
The issue was that the client would try to search for cfg file as per its rules and ignore the specification in the dhcpd configuration file. The solution was available on the <a href="http://www.syslinux.org/wiki/index.php/PXELINUX#Can_I_send_information_to_PXELINUX_via_special_options_in_the_DHCP_response.3F" target="_blank">syslinux wiki</a> in response to<br />
<blockquote class="tr_bq">
Can I send information to PXELINUX via special options in the DHCP response?</blockquote>
It is much harder syntax than the dnsmasq's dhcp-option-force but worked. <br />
<br />
<br /></div>
seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com0tag:blogger.com,1999:blog-6435266617173487253.post-56330961539242030812013-03-30T15:48:00.003+05:302013-03-30T15:48:57.142+05:30Install an OS from a DVD iso without booting<div dir="ltr" style="text-align: left;" trbidi="on">
While <a href="http://sethanil.blogspot.in/2013/03/ltsp-on-fedora-18-using-client-created.html" target="_blank">experimenting with LTSP on Fedora18</a>, I realized that I would have to have a supported environment in order to be able to understand the failure on Fedora. I had an iso file of Scientific Linux 6.3 and decided to use that.<br />
<br />
Since ltsp-build-client installs an OS in a chroot environment while the system is operational, I decided to see if I could use a LTSP script to install the Scientific Linux on a free partition.<br />
<br />
A python program, chroot-creator, seemed a likely prospect.<br />
<ol style="text-align: left;">
<li>Commented a few lines in chroot-creator meant specifically for LTSP clients. </li>
<li>Chose a suitable kickstart file </li>
<li>Loop mounted the iso image and used it as the yum repository</li>
<li>Started installation on on the free partition which failed.</li>
</ol>
Installation was not possible as the partition needed to be mounted and the chroot-creator installs the OS in a directory which should not be existing. So, the installation was successfully done in a directory 'Install' under the mount point.<br />
<br />
After the installation:<br />
<ol style="text-align: left;">
<li>In Install: <br /># mv * .. </li>
<li>Modify fstab file for Scientific Linux</li>
<li>Run grub2-mkconfig. It should find and include the Scientific Linux partition. </li>
<li>Chroot to the SL partition</li>
<li>Change password for root. Create additional users if needed.</li>
</ol>
Scientific Linux should now be a usable boot option.<br />
<br />
This process should work with any distribution which is compatible with yum on Fedora.<br />
<br />
Note: the experimental version of LTSP scripts now uses mock and chroot-creator program is not included. </div>
seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com0tag:blogger.com,1999:blog-6435266617173487253.post-59806478360086068852013-03-30T15:02:00.000+05:302013-03-30T15:13:12.837+05:30LTSP On Fedora 18 using client created on Ubuntu 12.10<div dir="ltr" style="text-align: left;" trbidi="on">
Exploration of<a href="http://ltsp.org/" target="_blank"> LTSP</a> turned out to be a very interesting challenge. My motivation was to write a <a href="https://sites.google.com/a/sethanil.com/articles/exploring-software" target="_blank">monthly column</a> for <a href="http://www.linuxforu.com/" target="_blank">Linux For You</a>.<br />
<br />
My primary system runs Fedora 18. I thought that I would be able to get the scripts to run on Fedora 18 in spite of the <a href="https://fedorahosted.org/k12linux/wiki/InstallGuide" target="_blank">explicit caution that Fedora 15 onward is not supported</a>. I haven't succeeded so far but I did succeed in getting an client image created on Ubuntu 12.10 to run on Fedora 18.<br />
<br />
I installed the server scripts from <a href="http://mirror.ancl.hawaii.edu/~k12linux/rpm/fc18/x86_64/" target="_blank">the repository for experimental version of LTSP 5 for Fedora 18</a>. This ensured that that the ldminfod version was compatible with the ldm version on Ubuntu 12.10 client.<br />
<br />
Ubuntu uses nbd by default. Unionfs root was not working with NFS root on Ubuntu as well. So, <a href="http://sourceforge.net/projects/nbd/" target="_blank">nbd version 3.1.1</a> needed to be installed on Fedora. The version in Fedora repository is 2.9.20. <br />
<br />
LTSP scripts run nbd server using xinetd while Ubuntu 12.10 runs nbd-server as a system service. Since the xinetd option did not work, nbd-server was started using a system service script. The key extract from nbd-server script is:<br />
<br />
<blockquote class="tr_bq">
DAEMON="/usr/bin/nbd-server"<br />
test -x $DAEMON || exit 0<br />
case "$1" in<br />
start)<br />
daemon $DAEMON 10809 -C /etc/nbd-server/config</blockquote>
The port has to be 10809 to be compatible with the -N option used by ndb-client on Ubuntu client.<br />
<br />
/opt/ltsp/amd64, /etc/nbd-server and /var/lib/tftpboot/ltsp/amd64 directories was copied from Ubuntu to Fedora. The following were the final steps:<br />
<br />
<ol style="text-align: left;">
<li>Run ltsp-update-sshkeys</li>
<li>Run ltsp-update-kernels</li>
<li>Run ltsp-update-image amd64 -f</li>
<li>Change the dhcpd configuration files to use the amd64 directory in tftpboot instead of i386. I modified the /etc/dhcp/dhcpd.conf file and did not use the ltsp-dhcpd script.</li>
</ol>
If all has gone well, you will get a LDM login screen with Ubuntu theme. The sessions available will be the ones on Fedora 18 and you should be able to login to a session using your Fedora 18 credentials!<br />
<br />
<br /></div>
seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com0tag:blogger.com,1999:blog-6435266617173487253.post-56138225711707534872013-02-22T11:46:00.000+05:302013-02-22T11:46:24.266+05:30Booting Porteus over the LAN from Fedora 18 server<div dir="ltr" style="text-align: left;" trbidi="on">
<div>
Continuing my experiments with diskless options, I was going through <a href="http://en.wikipedia.org/wiki/List_of_Linux_distributions_that_run_from_RAM" target="_blank">RAM resident distributions on Wikipedia</a>. <a href="http://porteus.org/" target="_blank">Porteus </a>appealed to me as it was able to run KDE desktop from RAM. The newly released version is packaged to boot off the network from a Porteus system with no additional effort.<br />
<br />
I wanted to boot from my existing Fedora 18 system and I wanted to avoid using tftp. The recipe I used is as follows:<br />
<br />
In order to make sure that both tftp and html could be used:<br />
<blockquote class="tr_bq">
<span style="font-size: x-small;">$ sudo ln -s /var/lib/tftpboot /var/www/html/tftpboot</span></blockquote>
<br />
Obviously,<i> httpd</i> and <i>dhcpd </i>are enabled. There is no need to enable <i>tftp</i> in <i>/etc/xinetd.d/tftp</i>. The following steps were needed in the tftpboot directory:<br />
<blockquote class="tr_bq">
<span style="font-size: x-small;">$ sudo mount -o loop Downloads/Porteus-v2.0-x86_64.iso /mnt</span><br />
<span style="font-size: x-small;">$ sudo mkdir /var/lib/tftpboot/porteus<br />$ sudo cp -r /mnt/boot/syslinux/* /var/lib/tftpboot/porteus</span></blockquote>
<span style="font-size: small;">Now, we need to <span style="font-size: small;">edit</span> <i>/etc/dhcp/dhcpd.conf</i>. It's content (for my netwo<span style="font-size: small;">rk) </span>will be:</span><br />
<blockquote class="tr_bq">
<span style="font-size: x-small;"># dhcpd.conf<br />#<br /># configuration for pxe from http://docs.fedoraproject.org/en-US/Fedora/17/html/Installation_Guide/s1-netboot-pxe-config.html<br />#<br /> option space pxelinux;<br /> option domain-name-servers 192.168.1.1, 8.8.8.8;<br /> option pxelinux.magic code 208 = string;<br /> option pxelinux.configfile code 209 = text;<br /> option pxelinux.pathprefix code 210 = text;<br /> option pxelinux.reboottime code 211 = unsigned integer 32;<br /><br /> subnet 192.168.2.0 netmask 255.255.255.0 {<br /> option routers 192.168.2.1;<br /> range 192.168.2.200 192.168.2.210;<br /><br /> class "pxeclients" {<br /> match if substring (option vendor-class-identifier, 0, 9) = "PXEClient";<br /> next-server 192.168.2.1;<br /> option pxelinux.pathprefix "http://192.168.2.1/tftpboot/porteus/";<br /> filename "http://192.168.2.1/tftpboot/porteus/pxelinux.0";<br /> }<br /> }</span></blockquote>
Finally, we need to copy the base os files into the http root, i.e.<br />
<blockquote class="tr_bq">
<span style="font-size: x-small;">$ sudo cp /mnt/porteus/base/* /var/www/html</span></blockquote>
<br />
We need to disable the welcome screen for Porteus to successfully boot from the apache server. So, comment all lines in<br />
<i>/etc/httpd/conf.d/welcome.conf.</i><br />
<br />
Now, restart the <i>httpd</i> and <i>dhcpd</i> servers.<br />
<br />
On the client machine, I am using <i>grub2</i>. The client is configured as follows:<br />
<ol style="text-align: left;">
<li>Download <a href="http://boot.ipxe.org/ipxe.iso" target="_blank">ipxe.iso </a></li>
<li>Extract <i>ipxe.krn</i> from the iso and copy it in /boot of the client.</li>
<li>Edit <i>/etc/grub.d/40_custom</i> and add the following lines:<br /><span style="font-size: x-small;">menuentry "ipxe"{<br /> linux16 /boot/ipxe.krn<br />}</span></li>
<li>Create a new grub.cfg<br />Fedora: <i> /boot/grub2/grub.cfg</i> using <i>grub2-mkconfig</i><br />Ubuntu: <i>/boot/grub/grub.cfg</i> using <i>grub-mkconfig</i></li>
</ol>
</div>
Reboot the client. Choosing the <i>ipxe</i> option should bring up the Porteus boot menu and it should boot into kde or lxde depending upon the option selected.<br />
<div>
<blockquote class="tr_bq">
<br /></blockquote>
<br />
<br /></div>
</div>
seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com0tag:blogger.com,1999:blog-6435266617173487253.post-56162280011725355842013-02-21T23:33:00.000+05:302013-02-21T23:33:01.040+05:30Booting over network - Use ipxe and forget etherboot/gpxe<div dir="ltr" style="text-align: left;" trbidi="on">
I was playing around with diskless options and decided to see if I could boot Puppy Linux over the network. As usual, it was easy to find a <a href="http://sirlagz.net/2011/06/13/how-to-boot-puppy-5-2-5-over-pxe/" target="_blank">recipe on the net</a>. I got the <a href="http://rom-o-matic.net/" target="_blank">gpxe boot linux kernel image for forcedeth driver. </a><br />
<br />
The surprise was the terrible performance I got on a 100mbps network. I did not wait for it to finish booting! On a 1GB network, the performance was 'merely' bad. I did not expect tftp to be so bad!<br />
<br />
Searching the net, I realized that gpxe allows html as the protocol instead. There was no change if I used pxelinux.0 and it was even worse if I used gpxelinux.0! I tried pxelinux.0 and gpxelinux.0 from <a href="http://www.kernel.org/pub/linux/utils/boot/syslinux/" target="_blank">version 5.01 of Syslinux</a> with no improvement. However, the performance was better on my lenovo netbook which needed the r8169 driver. The performance using html protocol was still not any better.<br />
<br />
The search for an answer led to the <a href="http://ipxe.org/" target="_blank">ipxe project</a>. Mercifully, the ipxe.krn from the iso file worked for both the cards. Now, the performance over html was significantly better. It took half the time to boot Puppy Linux using html protocol. <br />
<br />
<br /></div>
seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com1tag:blogger.com,1999:blog-6435266617173487253.post-58279374720236581502013-01-18T22:38:00.000+05:302013-01-18T22:42:39.733+05:30Upgrading to Fedora 18 using Yum - Nouveau causes system freeze?<div dir="ltr" style="text-align: left;" trbidi="on">
The<a href="https://fedoraproject.org/wiki/Upgrading_Fedora_using_yum" target="_blank"> documentation for upgrading fedora using yum</a> seems to be much better than before. A <a href="https://github.com/xsuchy/fedora-upgrade" target="_blank">very nice script which automates the instructions</a> was terrific. The upgrades of my desktop and the netbook were very smooth. After the upgrade, I installed the Cinnamon desktop as well. It is very nice though I will stick to KDE as I am now comfortable with it.<br />
<br />
There was, however, a surprise on the desktop. On booting into Fedora 18, the display vanished and the system hung. The system came up in muti-user mode but not in graphical interface. Gdm was the problem. I switched to kdm. The login screen came and was fine in KDE. However, the system again froze when I tried Cinnamon or Gnome desktops. LXDE worked but the system froze as soon as I started Firefox!<br />
<br />
KDE desktop was working with desktop effects disabled. If I enabled them, the desktop froze.<br />
<br />
The desktop worked fine with the nomodeset option for booting the kernel. However, it was using the vesa driver. So, the problem is with nouveau driver on "GeForce 6150SE nForce 430" hardware.<br />
<br />
Another curious result. The system is working fine with the kernel 3.6.11-1.fc17.x86_64 from fedora 17, which has made it possible to continue with Fedora 18 on the desktop.<br />
<br />
Need to reconfirm the problems I faced on the desktop as I did not find a bug report with similar issues. <br />
<br />
On Lenovo S10-3, I have so far not faced any issues related to the upgrade.</div>
seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com0tag:blogger.com,1999:blog-6435266617173487253.post-9008642567250429032012-12-31T22:31:00.000+05:302012-12-31T22:31:43.624+05:30FBReader on Android<div dir="ltr" style="text-align: left;" trbidi="on">
Finally, I used the FBReader on an Android tablet. It is far easier to read on it than I had expected. The 7inch screen is a very convenient alternate to the paperback.<br />
<br />
I ended the year 2012 by reading two stories - perhaps symbolic for the last day of the year.<br />
<br />
<a href="http://www.gutenberg.org/ebooks/21279" target="_blank">Kurt Vonnegut's 2BR02B</a> and<a href="http://www.gutenberg.org/ebooks/5200" target="_blank"> Kafka's Metamorphosis</a>.<br />
<br />
I had read Metamorphosis 40 years ago and its impact had been so strong and saddening that although I had downloaded the book months ago, I had been hesitating to read it again. Yesterday, I heard <a href="http://www.guardian.co.uk/books/audio/2012/dec/28/hanif-kureishi-franz-kafka-hunger" target="_blank">Kafka's A Hunger Artist</a> and overcame my hesitation. Rereading it was an amazing experience even on a tablet.</div>
seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com0tag:blogger.com,1999:blog-6435266617173487253.post-63982350553252392822012-11-03T14:14:00.000+05:302012-11-03T14:14:06.625+05:30Renewing and speeding up my desktop<div dir="ltr" style="text-align: left;" trbidi="on">
I had decided to buy a new desktop as the current one seemed too slow. It just did not seem useful to buy more cpu cores for primarily browsing the web.<br />
<br />
I had been looking for solid state disk options for the last few months after reading about their prices crashing. Unfortunately, this was not reflected in the prices of these disks in my area. However, recently I found an online store offering a reasonably attractive price for a 60GB SSD. It was delivered to me the day I read <a href="http://meta.slashdot.org/story/12/10/11/0030249/linus-torvalds-answers-your-questions" target="_blank">Linus Torvalds<span class="bodytext">"Get thee behind me,
Satan" comment</span> </a>. A very nice coincidence.<br />
<br />
Indeed, my desktop's performance now is terrific. I can save it from a landfill for another few years :)</div>
seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com0tag:blogger.com,1999:blog-6435266617173487253.post-26594072757889215392012-08-11T15:06:00.000+05:302012-08-11T15:06:46.364+05:30VBA Macros of Indian Income Tax forms failed on current LibreOffice<div dir="ltr" style="text-align: left;" trbidi="on">
I had experimented with filing Indian tax returns using OpenOffice<a href="http://sethanil.blogspot.in/2010/08/income-tax-returns-using-openoffice.html" target="_blank"> earlier</a>. Last year, I had used LibreOffice and filed my return. The effort was minimal as I had not felt the need to document it.<br />
<br />
This year, the result was painful. The simplest of forms failed with LibreOffice 3.5 and I could not even make any sense of the problems. I tried older versions (3.4) that I found on some of my partitions and those failed as well.<br />
<br />
In desperation, as the deadline was approaching, I downloaded OpenOffice and, surprisingly, that worked on ITR1 (simplest return). However, editing the macros needed for the other forms was a pain. Running the macro from within the editor started the execution from the first line of the file and not from the selected macro. I found the behavior confusing in comparison to LibreOffice and preferred to give up :)<br />
<br />
I realized that I had used version 3.3 last year and I had an old partition with an old version of ArchLinux - which had the 'right' version of LibreOffice. The process of filling the tax return forms was very tedious. I had to find the password for the sheets, unlock them and make some manual changes to the cell formulas. However, at the end of it, I did manage to submit the returns using the open source tools. <br />
<br />
I had planned to experiment and see if I can find out what changed from LibreOffice 3.3 to 3.4 to cause this 'regression' but now I will wait till the 3.6 version is available through ArchLinux or Fedora.<br />
<br />
Meanwhile, I plan to preserve the old ArchLinux partition for next year and, hopefully, thanks to this entry, I won't struggle too much.</div>seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com1tag:blogger.com,1999:blog-6435266617173487253.post-92227979006475918532012-06-26T10:45:00.000+05:302012-06-26T10:45:44.978+05:30Drupal 7 - Creation of Content Disappeared - Problems of Point and Click<div dir="ltr" style="text-align: left;" trbidi="on">
I have been exploring Drupal 7, particularly in trying to control access to creation of content followed by moderation by the appropriate editor. Even though I may be convinced that the level of control sought is unnecessary; but since it should be doable, might as well make it available.<br />
<br />
I added the Workbench Access and Workbench Moderation modules. After I had suitably configured everything along with LDAP authentication, I found that the content just could not be created. I repeated the process, without LDAP, and still the same result.<br />
<br />
I created a new content type and it worked the way it was intended. I just could not figure out what was going wrong with existing content types.<br />
<br />
In a moment of "inspiration", I decided to examine the Navigation menu. As the Workbench user interface includes a tab for creation of content, I had excluded the "Add content" and subsidiary content creation entries from the Navigation menu. The new content type I created had the entry in the sub-menu enabled. Since the parent "Add content" was not in the menu, the child entries were not visible.<br />
<br />
I enabled the existing content types in the Navigation menu and the content could indeed be created by the correct users.<br />
<br />
Finally - after going around in circles for over a day! In retrospect, that wasn't too bad.<br />
<br /></div>seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com0tag:blogger.com,1999:blog-6435266617173487253.post-135399674660745432012-06-22T12:25:00.000+05:302012-06-22T12:25:39.051+05:30OpenLdap, Fedora 17 and Modifying Schema<div dir="ltr" style="text-align: left;" trbidi="on">
Continuing <a href="http://sethanil.blogspot.in/2012/06/openldap-slapd-fedora-17-and.html" target="_blank">my experiments with OpenLDAP</a>, I needed to add mail attribute, which requires inetorgperson.schema. As I had not included it in the beginning, I wanted to modify the schema. It should not be hard but I couldn't find a simple answer.<br />
<br />
The discussion <a href="http://www.linuxquestions.org/questions/linux-server-73/how-to-add-a-new-schema-to-openldap-2-4-11-a-700452/">"how-to-add-a-new-schema-to-openldap-2-4-11"</a><a href="http://www.linuxquestions.org/questions/linux-server-73/how-to-add-a-new-schema-to-openldap-2-4-11-a-700452/" target="_blank"></a> gave a hint. Ldif files were needed and Fedora distribution includes them. So, I tried the the command<br />
$ sudo ldapadd -Y EXTERNAL -H ldapi:/// -f /etc/openldap/schema/inetorgperson.ldif<br />
<br />
And it worked. However, since migration tools use the <a href="http://www.openldap.org/lists/openldap-software/200307/msg00267.html" target="_blank">objectClass account which is inconsistent with inetOrgPerson</a>, it turned out to be easier to recreate the ldap database.</div>seth.anil@gmail.comhttp://www.blogger.com/profile/05691472392159378214noreply@blogger.com0