Skip to content

Archive for

23
Mar

Issue on running grunt. Error: Cannot find module ‘findup-sync’

grunt error

This problem occurs when I archive the whole node_modules directory (including the grunt command) to another machine. I have to do this because I have to create an Ubuntu 14 ISO for offline installation containing grunt as a requirement. Generally, this copy across approach works fine but not straightforward for grunt.

Although reinstalling grunt on the target machine works, it is not an option to me,

npm install -g grunt-cli

The real problem is actually the executable, /usr/local/bin/grunt, that is supposed to be a symbolic file which links to ../lib/node_modules/grunt-cli/bin/grunt. Copying across can break the symbolic link which causes the above error when running it. Rebuild the symbolic link and the problem is resolved.

 

Advertisements
23
Mar

Checklist to configure headless and offline Ubuntu 14 system

Headless

Grub Failsafe boot

Set the boot failsafe prompt to have some timeout instead of indefinite wait

echo 'GRUB_RECORDFAIL_TIMEOUT=5' >> /etc/default/grub
update-grub

Grub RecordFail boot

In some cases, a power outage can cause the Ubuntu stuck in the GRUB menu indefinitely in the next boot which causes headless system to hang. Here is more info of the issue. To avoid that, add the following line to /etc/default/grub:

GRUB_RECORDFAIL_TIMEOUT=$GRUB_TIMEOUT

Then runs update-grub. Alternatively, runs this command and it will remove the issue in the next boot.

grub-editenv create

Fsck fix

Don’t ask when fs needs checking

echo 'FSCKFIX=yes' >> /etc/default/rcS

Offline

Automatic Check New Release

/etc/update-manager/release-upgrades

[DEFAULT]
Prompt=never

Apport – sending bug/crash reports

/etc/default/apport

enabled=0

Postfix – Mail transfer agent

update-rc.d postfix disable

apt-check – periodic apt check

/etc/apt/apt.conf.d/10periodic

APT::Periodic::Update-Package-Lists "0";

More to come when I find out more ….

14
Mar

Building ExtJs/Highcharts Application with Sencha Cmd 4 Tool

Here is a blog showing you how to build application with the Highcharts extension using Sencha Cmd 4 tool. First of all, we generate ExtJs 4 application skeleton with the following command example:

~/bin/Sencha/Cmd/4.0.4.84/sencha -sdk extjs4 generate app SenchaCmd4Demo sc4demo

Next we copy (don’t use symbolic link) the whole ‘Chart’ directory into the application directory.

cd sc4demo
cp -fr {path}/{to}/Highcharts_Sencha/Chart .

Read more »