Showing posts with label Linux. Show all posts
Showing posts with label Linux. Show all posts

Tuesday, November 1, 2022

Edit PDFs in Linux with Firefox 106

Did you ever receive a PDF form in Linux and wish there was an easy way to edit it with your information before returning it?

Well now you can with Firefox 106.

It is now possible to edit PDFs: including writing text, drawing, and adding signatures.

Firefox Release Notes



Friday, January 1, 2021

Firefox starts minimised and doesn't respond

If you have the same problem as me, try this:

1 - If you have used different instances of Firefox from the same account, in my case Firefox ESR and Firefox latest release, enter the following in the Firefox title bar and delete unused profiles. (DO NOT delete profiles that are in use, you will lose history, logins, cookies etc for that instance of Firefox). 

about:profiles.

The image below shows the page after deleting the unused profile.

 
 
2 - Close Firefox and delete xulstore.json, which you will find in a location similar to this (in Linux) 

/.mozilla/firefox/[random characters].default-[version]

The file stores Firefox's information about window positioning. Mozilla Support. It can become corrupted - Firefox will recreate it when it is started again.

As I say: this worked for me. I suspect the issue was caused because I ran a release version of Firefox from my /home directory (without possibly setting up profiles correctly, it has to be said) and this somehow corrupted Firefox's window positioning on opening.

The steps above corrected the issue on two separate Linux computers, so if you have the same issue, give it a go. Please don't delete profiles that are in use.

Deleting the xulstore.json file in a profile folder may actually be enough to fix the problem - I didn't test this, which might be a good first step to try. However, I wasn't using Firefox from my home directory any more, so deleting the profile wasn't an issue.




 


Defrag Linux and Speed Up Your Computer*

*Terms and conditions apply.

When I used to use Windows (XP), I used to spend a lot of time looking at little coloured blocks moving around the screen as I ran a defragmentation utility every week or so.

I recently came across an online article which mentioned tools to defragment the Linux Ext4 file system, used in many Linux distributions up to now (Fedora is moving to the Btrfs system, apparently). The article I read actually compared Btrfs to Ext4, and mentioned that Ext4 is "effective at preventing fragmentation over extended periods of time". Fedora Magazine.

I found a useful article on how to use the defragmentation tool in Linux, and gave it a go. I used the command to get a fragmentation report:

# e4defrag -c /

Result: I don't need to defragment, no moving coloured blocks, Linux is boring.

Quite possibly, so is Windows now. Does it still get fragmented? I don't know.

When can Ext4 become fragmented? When the HD is very full, seems to be the answer, according to How-To Geek, which also has a good simple explanation of why Ext4 doesn't usually get fragmented.

Checking in my notebook, I noticed that I'd made a note of this command previously, and forgotten about it, so I thought I would do a post on the subject.

I couldn't resist a click-bait title: obviously you are not going to speed up your computer doing this, unless, possibly, your HD is very full, in which case a better solution might be to declutter some data to an external drive.

File under: not really relevant.



Tuesday, June 11, 2019

10 years of Linux, and this blog!

Ten years ago I destroyed my last Windows installation (by accident) while installing a Linux distribution. I had been dual-booting Linux for a couple of years before that, and had been using Linux exclusively on my older laptop for sometime. No big regret (Except for Half Life).

So, for ten years, I and my spouse and my children have all been using Linux quite happily (or perhaps it might be fairer to say obliviously for most members of the family).

So why Linux?

Well, first of all, because of Firefox. When I first got online at home in about 2003, Internet Explorer was dreadful. A quick history lesson:
[Microsoft] missed the world wide web and then set out to exterminate the one company – Netscape – that hadn’t.

In the 1980s and 1990s, it wielded its monopoly power ruthlessly and effectively. It wilfully destroyed the most creative startup of the early web.
The Guardian.

Firefox (originally named Phoenix) arose from the ashes of Netscape. It was something new to me - open source software - and it was good. It worked well, it was secure, it looked good, it encouraged open standards and the development of the web, and it was free (as in beer)!

At that time I was using a lot of software gleaned from free CDs which came with computer magazines, installation CDs borrowed from other people, and downloaded freeware programs.

I time went on, I became aware of open source alternatives and started using them. The Gimp replaced the ancient version of Photoshop, Open Office replaced the outdated Microsoft Office program, and Amarok replaced Winamp.

Making the leap to an open source operating system was a obvious next step.

As well as being "free as in beer", open source software is also "free as in freedom" - when you can see the source, you can make any change to it that you want which appealed to me. And of course, the software is only free in price because it is a collaborative exercise, made possible by the freedom to see and alter the code.

I'm not a computer programmer, so I haven't contributed to open source software by writing code. I've dabbled in customising themes for various programs, and enjoyed customising the desktop in Gnome, XFCE and OpenBox. And I've tried to help other people use Linux with this blog, so I hope I'm not a complete freeloader.

The choice in software in Linux is huge, and the possibilities of customisation are limited only by your interest and coding ability.

A second reason is that Windows, for me at least, is not as good as Linux.

The original XP which came on my Internet connected laptop was dreadful (I'd had a previous laptop which ran CP/M, the operating system which Microsoft ripped off to make MSDOS, but that's another story.) OK, SP2 was a lot better and SP3 was good, but it still took about ten minutes to shutdown, presumably because of registry cruft.

By that time, I'd jumped ship.

I have used or worked on or administered Windows computers since then and Vista was dreadful, 7 was pretty good, 8 was awful and 10 is OK, apart from the updates nightmare. My newest computers came with Windows 10, but I was never tempted to keep it.

For me (and the family - nothing stress tests a computer better than children), Debian 9 has been 100% reliable for the last couple of years. My younger daughter managed to induce a kernel panic in Debian 8 from time to time with random keystrokes (she was only 2!), but my eldest daughter has been using Linux since age one without issue or complaint - and she uses Windows at school, so it's not as if she has nothing to compare it to.

Another reason to run Linux has been that it works better on bottom-end computers which often struggle to run windows, even though they come with it installed. Fr example, both this laptop and the family all in one computer are definitely not high powered machines. Purchaser reviews for both machines often complained that they were slow, but both are quite happy running Debian.

As I mentioned, Windows 10 isn't too bad, but the updates issues are not something I would no like to face myself- updates installing at inappropriate times, failing to install, getting stuck, and the endless enigmatic messages.


Updates in Linux have always been quick and easy. No endless downloads or forced reboots, and if you really want to know what is going on, you can read the terminal output. A lot of the problems with Windows 10 update seem to be with feature updates these days, and it's fair to say that a Linux upgrade requires some technical knowledge, but it's not really that difficult. (Here's a how-to for Debian from Make Tech Easier.) If that puts you off, remember that most Windows 10 users are running a feature update from over a year ago, because they are either unwilling or unable to update. (BetaNews, Slashdot).

And of course, security in Linux is less of a concern. In Windows I was always trying out different anti-virus and firewall programs, whereas I don't use an anti-virus program in Linux. I have tried out some of the Linux ones, but now just don't find one necessary on the home desktop. The update process itself makes Linux more secure, since it updates almost everything on the system. You don't have Internet-facing applications or hardware drivers that don't get updated unless you check with their third-party authors or run a vulnerability checking scan tool.

Hence the fact that the emphasis of this blog has changed over the years. In fact, I notice it has been almost 10 years that I have been writing this blog, as well as using Linux!

Perhaps it might be time for a name change?

Saturday, May 4, 2019

Debian Buster preview

Two and a half years ago, I updated this computer to Debian Stretch while it was still Testing (the pre-release version) but in freeze (a stage when no new packages are added and bugs are ironed out).

Stretch has been a rock solid and reliable Debian release, both on this machine and on a later purchase, now the main family computer. But with a new version approaching, I always get the urge to try it out.

So, a few days ago, I updated the older computer, now rarely used, to Buster, which again is still strictly Testing but in freeze.

I'll make the same warning as I did at that time: Buster is still in Testing and can break. If it breaks, you get to keep the pieces.

So here is Debian Buster:
I have to confess I ditched the doggy wallpaper straight away and used the Moonlight wallpaper by Juliette Taka Belin.
Back in 2016 I wrote "The update was pleasantly painless with no issues". This time I wasn't quite so lucky. I ran out of disk space during the installation, and got this message:
No space left on device
I had tried to check if there was enough space for the upgrade using a command I found here (which suggested I had just barely enough). This computer has a separate root partition, given the default size of 10GB by the installer. This default size is really too small nowadays- at least for a Gnome install update.

Luckily I was able to run apt-get clean and apt-get autoclean to make enough space to finish the upgrade. Although I was given an error message before I could continue:
dpkg was interrupted, you must manually run 'dpkg --configure -a' to correct the problem 
When the upgrade completed, I rebooted the computer but it froze with just the cursor visible in the top left of the screen. That's my installation borked, I though, and went to bed.

However, the next morning I found I could boot into Rescue Mode and get a command prompt. I cleaned up the disc and found I could load the default installation. Hurrah!

Now I have Gnome running reasonably well. It does seem a bit slower than Stretch at times, despite the claim that Gnome 3.30 is lighter on resources. I may try a clean install at some point to see if that makes any improvement. This is a very low spec machine, it has to be said.

The most obvious change in is a switch from an icon grid to a sidebar list in Gnome settings. There are also minor changes to the file manager, and the addition of a Night Light mode, which changes the screen to a sepia tone, which apparently reduces eye stain at night.

One bug I have found so far is that the Gnome file manager does not create thumbnails for image files. This is a known bug, and quite easy to rectify by installing libgdk-pixbuf2.0-bin.

For me,  Stretch was a big improvement over Jessie. This update by comparison seems to add only minor improvements. My impressions so far are good, but I can live with my Stretch install on my main computer for a while. I will see what bugs get knocked out of Buster (a few fleas?) before updating it.

At least having an old laptop around I can scratch my update itch without inflicting those fleas on the family.


Saturday, January 21, 2017

EFI Vs BIOS

I have a new computer, which came with Windows 10, and I wanted to install Debian on it. With my previous laptop, I ended up wiping the disk, destroying the EFI partition, using BIOS emulation and a MBR, whether by my clumsiness or the installers (Jessie) I don't know.

Since then I've been wondering: is there any advantage to an EFI install? Should I at some point recreate an EFI partition on my laptop and reinstall Debian (it has been working well for- checks- almost two years)?

So now I was wondering, shall I do the same thing with the new computer? Or try an EFI install keeping the EFI partition?

Is there really any advantage to EFI, beyond handling 2TB disks that computers don't come with yet, at least in my price range?

I found this from Rod Smith at ask ubuntu:

There are several advantages to GPT:
  • Supports disks larger than 2TiB. 
  • Supports partitions larger than 2TiB. 
  • Supports more than four partitions, with no distinction between primary, extended, and logical partitions. 
  • Uses GUIDs as type codes, which means there's less risk of conflicting/duplicate codes. 
  • Uses LBA addressing exclusively, compared to MBR's dual use of LBA and CHS. (Even on MBR, CHS is useless on disks over about 8GB, though, so there's little risk of real conflict on modern hard disks, which are much bigger than this.) 
  • Provides duplicate partition table structures at the start and end of the disk, which makes recovery from some types of user errors, bugs, and disk damage possible. 
  • Provides checksums of important data structures, which enables detection of some types of partition table damage. 
  • Provides a UTF partition description field, so you can give your partitions names. Note that this is independent of the name of the filesystem contained in the partition. 
  • Is used natively by EFI/UEFI firmware.
"Most of these advantages are minor ones for most installations", as Rod says. So no reason to reinstall on the laptop I think, but worth trying an EFI install on the new computer.

In the end, the install was very easy: whether down to my expertise or the installers, this time I do know- the Debian Stretch (alpha) installer identified the EFI partition and used it.

So, it looks like EFI wins, by a hair, and if it doesn't work, and BIOS emulation is available, it's not that much of a big deal to use it, unless any of the above issues are of vital importance.

Thursday, January 3, 2013

Trojan Horse for Linux?

I came across this post on the avast! forum recently. Trojan Horse for Linux, it declares. OK, it's Symantec that called it a Trojan Horse, but wrong: it's a malicious Apache Module.

Yes, Linux malware does exist. Who should be worried? In this case, administrators of Linux servers, as the attack vector of this malware is unknown, and it seems to have been placed on servers with good security.

This is not a Trojan Horse that desktop users of Linux are going to have to worry about downloading from the internet.

I recently wrote that Desktop Linux needs anti-virus like a fish needs a bicycle. I'm glad I put that "Desktop" in there. Virus programs like Symantec and ESET do detect this malware. This VirusTotal result I found suggested that the detection rate among anti-virus programs is pretty good. An anti-virus scan of a server may pick up a hack like this.

But I'm writing for users of Desktop Linux. The existence of a targeted hack against Linux servers or the existence of Linux malware on servers is not reason for desktop Linux users to worry.

When it is time to worry, you'll read it here.

Wednesday, August 29, 2012

My new Linux computer

This is my new Linux computer. Well, it's my daughter's, really, but I've been playing with it too. I know it runs Linux because somebody has hacked it.

Sadly the software that comes with it to allow download of new games and ebooks is not Linux compatible. Although I eventually got the Learning Lodge Navigator working on PlayOnLinux (Debian has a very old version of Wine- PlayOnLinux downloads the latest version), the USB to the Innotab didn't work.

Looks like I'll be needing to borrow a Windows computer.

I had better luck putting content on the SD card I bought (memory cards are astonishingly cheap now- 8GB for under £4!). Create the directory structure and convert videos as described on A Maggid's Musings. (I added a comment with an alternative parameter to make videos full screen which I used when resizing videos for Android.) I had no problem playing an MP3 file I put on the card, unlike some people.

Of course I had to mount the SD card first. I have an SD slot in my laptop, but it doesn't seem to work in Debian. I must try and get it working, but in the meantime, I bought a £1 card reader from PoundWorld.

It works. As did the bluetooth dongle I bought for a pound.

Friday, June 10, 2011

Do I need an Anti-virus program on Linux?

This is a question often asked by new users of Linux. (See here.) The short answer often given is no, but that answer often stirs controversy. (See here.)
I haven't used an anti-virus program in Linux for years (although I've tried all the free ones). My answer to the question, as a home user of Linux only computers who doesn't share files with Windows users is also no. Obviously I've caveated that answer, and there are plenty more caveats, so here are some points to beware.
  • Saying that you don't need an anti-virus doesn't mean that Linux malware doesn't exist. It does.
  • Saying that you don't need an anti-virus doesn't mean that you don't need to be careful about security in Linux. You do.
  • For new users of Linux, that attention to security means getting software from the distributions digitally signed software repository, or trusted sources. (For example, I have installed software from Opera and HP in addition to software from the Debian repository.) This guide is not intended for or likely to be useful to more advanced users of Linux.
  • Linux malware exists, but Linux users are very unlikely to encounter it. Don't go downloading packages form the internet and you won't. (Obviously, with so much free software available in distribution repositories, Linux users won't be on crack sites or peer-to-peer networks downloading dodgy executables that claim to unlock Windows programs.)
  • Most Linux anti-virus programs don't do the background scanning of files that Windows anti-virus programs do. If you want to scan a file, you have to do it manually.
  • Why use one installed scanner to scan a file when you could send it to Virustotal and have 30 or so scanner check it? (And please see the point above about not downloading packages from untrusted sources in the first place.)
  • Linux users are simply not affected by the web-borne exploits that install software willy-nilly on Windows systems.
  • Most Linux anti-viruses are primarily intended for file servers, not desktop environments. Yes, an anti-virus is recommended in that situation- beyond the scope of this simple guide. But if you have a dual partition with Windows, or share files with Windows users, yes, an anti-virus is useful- but you'll be looking for Windows viruses.
  • There is no certainty that anti-virus programs will detect a malicious file, as I demonstrated here and here.
  • Linux anti-virus programs are meant as file scanners, not system scanners- scanning the /root (system) directory is likely to result in a lot of frightening warnings (for the new user) which actually don't indicate any sort of infection. See here and here.
  • Institutional network users running Linux may well be asked to use an anti-virus program- I'm not here to contradict your system administrator. Mostly the concern is that Linux users will pass Windows malware around. But there is also the possibility that these users will have valuable information and may be targeted by criminals- and receive a Linux Trojan in their email inbox, for example.
  • Where untrusted and possibly malicious people have physical access to a computer, there is the possibility that they may try to run malicious software. This area is outside my experience. Untrusted people don't use my computer. In institutional situations like this, the answer may be yes, an anti-virus might be a good idea. Listen to your system administrator or consult a more advanced guide.
  • Most of the people advising that home users of Linux need an anti-virus program are Microsoft shills spreading FUD. The idea that you can run a computer connected to the internet without anti-virus protection or risk of infection tempts users away from Windows, and Microsoft has never been above a little black propaganda. More importantly, these people don't actually look at the evidence when they tell you it's not safe to run Linux without an anti-virus.

Friday, May 6, 2011

2.6.39 kernel will drop 686 flavour

Updating my Linux kernel recently in Squeeze (and previously in Lenny), I had to chose a 'flavour' to match my CPU architecture. For me this was the 686 flavour- compiled and optimised for modern multi-core chips.
An email from Debian Project News recently informed me that the 686 flavour kernel is to be dropped.
From the information linked to at Ben's technical blog, it seems I'll be able to use the '686-bigmem' flavour- even though my computer only has 1GB of memory- with a tiny hit on performance but a slight security advantage:
Even those that have less than 4 GiB RAM do support PAE and can run the '686-bigmem' flavour. There is a small cost (up to about 0.1% of RAM) in the use of larger hardware page tables. There is also an important benefit on recent processors: the larger page table entries include an NX bit (also known as XD) which provides protection against some buffer overflow attacks, both in the kernel and in user-space..
There are a few 686-class processors that won't be able to use 686-bigmem and which will have to use the 486 flavour- apparently with a performance gain (see the blog for details).

Tuesday, March 1, 2011

Quod Libet

Rhythmbox (the music player that comes with Debian) is pretty good. Fine most of the time. But it does have a problem with compilation albums. Investigating the issue before, I'd found that Banshee will play compilation albums correctly, but in the process of installing it on Squeeze I noticed it has an obsolete dependency bug, so I gave it a miss. On a whim I tried Quod Libet again. Lenny came with version 1 which didn't impress me too much, but Squeeze has version 2 which is a big improvement. It recognised my compilation albums correctly- and what's more its excellent tag editor allowed me to fix some tagging errors I hadn't noticed before.
The default GUI is pretty basic, can be customised to show a paned browser, album covers, a search feature, playlists etc. (These features are also available in a separate window.)

The basic GUI:


Album cover view:


The Tag Editor:


The download album art plugin:


Quod Libet comes with many plugins that can be enabled if desired. I really liked the album cover search feature which works really well- no more Google searches and file saving- it's all automatic.
I also used the notify plugin to get new track notifications, and the tray icon plugin to put the music player in the notification area rather than close it completely. (I like to keep the bottom panel for documents and keep my music player separate.) This is probably the weakest feature of the player (although it is only a plugin.) Hovering over the Quod Libet icon only gives track information- not album art and track progress like other players. The panel icon is also indistinct when paused (a bug?)
[Update: not a bug. The plugin superimposes the Gnome paused icon (which depends on the theme selected) over the Quod Libet icon. Unfortunately in a dark panel, the Quod Libet icon does not display well, as it is black with a white border (so only the border shows. Editing the Quod Libet icon to white helps.]
Other plugins worth a look would be the MusicBrainz and CDDB lookup plugins for identifying audio tracks. (I looked previously at other programs using MusicBrianz and CDDB.)
Despite the minor gripe about the tray icon plugin, I'll give Quod Libet five stars for handling compilation albums, having one of the best tag editors around, a brilliant album cover finder and an elegant and customisable GUI. And I haven't looked at all the features yet- for example, Quod Libet claims to be better able to handle large music libraries than other players.

Monday, July 26, 2010

MSN video chat in Linux

Most computer users use Windows, and most of them use MSN for messaging. So how do you talk to them in Linux? Pidgin works fine for chatting over the MSN network in Linux (Gnome), but nothing works with video chat with sound.
Yesterday my wife asked me to set up a video chat with her friend (who uses Windows). This I had done previously by booting into Windows and using Live Messenger, but recently I deleted my Windows partition. I tried something I'd heard about previously: Meebo, "the web platform for IM on any network or site."
Frustratingly, I could see my wife's friend's webcam, but my own remained inactive. Embarrassingly, I had to concede that I couldn't set up video chat.
Later, I was Googling for an answer and came across this information:
You need to allow meebo access from the settings manager, go here. Look for mee.tokbox.com set to always allow. This works on a few other websites too. The problem is when you set it to allow while in the website for whatever reason it doesn't actually do it.

Also after setting it to allow restart Firefox
I've allowed Meebo in Flash player privacy settings, now I'm just waiting for an opportunity to test video chat.


UPDATE: Success!


Update: It looks like Flash 10 may not be able to access webcams because of a bug. Of course that bug may or may not have been fixed by the time you're reading this. If you follow the steps above and still can't see your webcam in Meebo, try here.

Wednesday, July 21, 2010

How useful is anti-virus in Linux? (Part 2)


In Part 1 I wrote about Linux malware found in a screensaver. In this post, I'm going to talk about a more recent story of a Trojan horse found in a Linux distribution. The story was picked up with glee by Ed Bott:
Every time I write about Windows security software, I get a predictable flood of responses from Linux advocates who claim that they don’t need any such protection. Today comes a shining example of why they’re wrong.
Then Adrian Kingsley-Hughes jumped on the FUD wagon. So should Linux users all be installing anti-virus software? I decided to investigate. With a bit of searching, I found an analysis of the malware script concerned. Submitting the script to VirusTotal produced no detections, but I'd found this blog post from Sophos describing how they detect the malware as Troj/UnIRC-A. Another analysis suggested the malicious package was still available for download. I checked, and it was. The file had already been submitted to VirusTotal in February 2010, when there had been four detections. (A reanalysis didn't produce any more.)



Despite the rather gloating blog from Sophos above, they only added their detection for this malware on the day the story broke. F-Secure added their detection the day after. I don't know when Comodo and Panda added their detections, but I'm guessing they too added their detections after the story broke.

So should Linux users be installing anti-virus products, and combing their systems for malware? There are two points to make here:
  • There's no evidence that any anti-virus product would have detected this malware before it was discovered and reported.
  • Well over a month after the malware was discovered, it's detected by a tiny minority of anti-virus programs.
The real moral of the story seems to be (as the Sophos blog points out) for administrators to check signatures and checksums of files when using a distro like Gentoo. [Some background I picked up reading the comments sections of various articles about the story: Gentoo is a far from mainstream distro which requires users to compile everything from tarballs.]
In more mainstream distros, software in repositories is digitally signed by the developer, so it is not possible for a package to be replaced with malware. When enabling additional repositories, or trusted third-part repositories, always may sure the appropriate key is installed so software can be authenticated. The following warning means the appropriate key has not been installed, and you are at risk of installing a possibly insecure passage:
You are about to install software that can’t be authenticated! Doing this could allow a malicious individual to damage or take control of your system.
See here for an example.

How useful is anti-virus in Linux? (Part 1)

In almost three years of using Linux, I've never come across any Linux malware.
I have come across two tales of Linux malware. I'm revisiting them now to ask: do these stories suggest that using anti-virus software is necessary or advantageous?
In December 2009, malware was found inside a screensaver on gnome-look.org. The malware was a "script with elevated privileges designed to perform a DDoS attack as well as keep itself updated via downloads".
The moral of the story was clear: don't install software packages from untrusted sources.
The malware script can be found in the Ubuntu forum post linked to in the story above, so I decided to save the script as a text file and send it to VirusTotal, to see how many if any anti-virus programs detect it. I found that somebody had already done this, a couple of days after the malware was discovered, and that no anti-virus program at VirusTotal had detected the script at that time.

I then hit the 'Reanalyse' button to see what the result would be seven months later.


This time, eight anti-virus programs detected the script as malicious.
The two points that can be made here are:
  • None of the anti-virus products on VirusTotal (which is most of 'em) would have detected this script as malware during the time it was available to download.
  • Even seven months later, only a small number of anti-virus programs would detect this malicious script.
To answer the question: is using anti-virus software necessary or advantageous in Linux? In the case of new Linux malware at least, the answer seems to be that anti-virus software has nothing to offer- caution remains the key.

Monday, January 18, 2010

Share files in a local network with NFS on Linux

Here's a really easy way to share folders and files between two Linux computers on a local network from mybeNi. (I've done it with Ubuntu and Debian.) It doesn't require the skills of a network administrator to implement, and uses NFS, which seems to be fast and reliable.
Here are the steps to go through- details are at the link above.

On the first computer:
Install NFS (either using Synaptic or the command line).
Edit an NFS configuration file to tell NFS which folder to share, which computer to share it with, and specify options.
Restart the NFS server.
On the second computer:
Install NFS.
Make a directory to contain the shared directory from the first computer.
Mount the directory.
Edit an NFS configuration file to mount the directory automatically if required.
Folder locations in the tutorial change be changed. For example, I shared...
/home/username/Shared
...on the first computer and created...
/home/username/Shared
...on the second.

Be carefully with typing the locations because case and spelling mistakes will mean the share won't work

For me, the tutorial didn't work at first. Then I noticed a comment which provided the answer. As described in later comments, I added lines to the /etc/hosts file on my computers to tell them the IP address of the other computer.

To edit the file:
sudo gedit /etc/hosts
Add:
'IP address' 'computer name', for example:
192.168.2.2 compaq
(To find the name of each computer, type the following in a terminal:
hostname)
Thanks to Beni for the tutorial.

Update: the original tutorial has gone, but I found a condensed version of it here:

==NFS shares
Condensed frm http://mybeni.rootzilla.de/mybeNi/2007/how_to_set_up_nfs_and_how_to_share_files_in_a_local_network_with_ubuntu_linux

====Share /media/music from 'ERNIE':
$ sudo apt-get install nfs-kernel-server

Add a line to /etc/exports:
$ ECHO "/media/music BERT(ro,async,all_squash)" >> /etc/exports

Restart the NFS Server
$ sudo /etc/init.d/nfs-kernel-server restart

====Connect and mount from 'BERT'
$ sudo apt-get install nfs-common
$ mkdir /var/music
$ sudo mount ernie:/media/music /var/music

To automount at start, add a line to /etc/fstab
$ ECHO "ernie:/media/music  /var/music     nfs r,hard   0  0" >> /etc/fstab

May have to add a line to /etc/hosts.allow

1. The server rejected the requests. What I did was I opened ports: 111, 2049, 32771 (from client and server, but not from router). This wasn't enough. I had to tell the servers firestarter to allow connections from my clients ip (in the lan).
2. Then I ran in to a new problem, but at least the server responded:
mount.nfs: access denied by server while mounting timo-desktop:/media/musiikki
Then I realized that for some reason I had to add the clients ip in to the file /etc/hosts
Like this
192.168.1.51 timo-laptop
after doing that and then I ran on the server:
sudo exportfs -ra
sudo /etc/init.d/portmap/ restart
sudo /etc/init.d/nfs-kernel-server restart

Monday, October 19, 2009

GB english spellchecker in Opera 10 on Linux


Opera 10 has added an inline spell checker which checks spelling in web forms, but the default (and only) dictionary in the Linux version is US English. Here is how to add GB English, and other languages.
Curiously, the Windows version already has a GB English dictionary option.
UPDATE: This post is now obsolete (and the link above dead). The current version of Opera has a menu option to add spell check dictionaries.

Saturday, September 26, 2009

Your operating system is not supported...

Looking into cable modem problems in Ubuntu recently, I came across a few horror stories about Comcast, the American ISP. Technicians who have never heard of Linux and insist they can only install the Internet to a Windows computer, that sort of thing. So it was a surprise to come across this blog post by a guy called Linus.
I guess it all depends on who you are, or possibly what you know.
So I need to provision it (ie letting Comcast know about the new modem MAC address), so I call up Comcast. It being a Sunday afternoon, I was expecting that I'll just have to wait for Monday to get it sorted out. But no, not only is there a friendly tech who is greeting me with neither silly muzak nor waiting, but she's happy to get my all provisioned and up and running with a new cable modem in minutes (ok, so it took more than a couple of minutes, but a lot of it was literally waiting for the new cable box to boot up a few times).
The clue in the image above is the telephone number: just call and ask for the ISP to provision your modem seems to be the answer.

Ubuntu and cable modems


The other day I was trying to help somebody on the Ubuntu forum get an internet connection. I didn't notice at first that it was a cable modem (of which I have zero experience), but when I did, I decided to look into how they work. (The thread is here.)
There seems to be a lot of confusion around as to how to get a cable modem connected and working with Linux, how to solve connection problems, and how to connect a different computer or a router.
Here are the myths:
  • Cable companies only support Windows or Mac.
  • You'll need to spoof the MAC address of the computer originally connected to the modem in order to connect another computer or a router.
Here's the reality:
  • ISP software may only work with Windows or Mac, and technicians may only know about Windows and Mac, but there's actually no obstacle to getting a connection. A modem connected to a cable network needs to be "provisioned": the cable company needs to know the MAC address of the modem. They can do this at their end, or the cable guy can do it at your end. If it's done at your end, the cable guy will need Windows or Mac. If you have Linux, the advice is: just get the cable guy to connect the modem and tell him you'll call the provider service line to provision the modem.
  • After connecting a different computer or a router to a cable modem, power down the modem for 10 minutes before connecting (the computer and/or router should be off while connecting too). Power up the modem> (router)> computer and everything should be fine (no need for spoofing). A good guide is here.
In Ubuntu, make sure DHCP is enabled unless the cable Internet provider has told you to use a static IP address.
The original poster at the Ubuntu forum thankfully managed to get his connection working, despite my fumbling around for a solution.

Sunday, September 13, 2009

Microsoft anti-Linux FUD

Microsoft doesn't want you to use open source software. And the way they get you not to use open source software is through FUD. The latest example can be found here, where MS is "indoctrinating" sales staff in the reasons customers wouldn't be happy with Linux.
Now it's perfectly true that Linux doesn't run Windows programs. If you really want to run MS Word, you'll need Windows; but if you use Open Office, you won't. Fair enough, customers should know this.
Linux doesn't run Windows games* (*Some will run in Wine, but the performance can be poor.) If customers want a games machine, they'll need Windows, fair enough, although I actually think a dedicated games console can be a better option- games take up huge amounts of disc space, require a powerful video card which can add the price of a games console to a PC, and if my experience with Half Life is anything to go by, can rip a HD to shreds with crashes while reading or writing to the HD leaving bad sectors.
Now we come to hardware. My printer, camera, MP3 player, wireless dongle and external hard drive all ran out of the box on Ubuntu Linux. I had to install some firmware for the scanner to work, but I'd've had to install a driver for it to work in Windows- in fact my printer doesn't work in Windows because I haven't installed the driver. Good manufactures support standards and Linux, and their hardware works in Linux. (HP is a shining example.) Verdict: FUD.
Finally, Internet Messaging. No, you can't get Window's Live Messenger on Linux. Yes, you can have IM with a multi-protocol IM client* like, in Ubuntu, Pidgin. (* Supports multiple accounts- MSN, Yahoo!, Google, ICQ etc.) No, Pidgin doesn't support video chat on MSN (and I don't know of any Linux IM client that does.) Linux does have Ekiga, a free video chat client, and Pidgin does support video chat on GMail, but I can see that it's not going to be convenient for a Windows users to get used to a new IM program, or a Linux user to video chat to a Windows user.
This is a big turn-off for prospective Linux users, or indeed, purchasers of Linux computers (netbooks, probably) who ask: where's Windows Messenger?
This is of course intentional: that's the way Microsoft works: get you used to their product so it's just too much effort to change.
Verdict:FUD. There's no reason to be locked in to Windows. There are alternatives to the Microsoft IM network.