Play Raspberry Pi(1)System and nodeJS/nginx
Download the software from here http://www.raspberrypi.org/downloads/
I prefer to try RAPBIAN, because I usually use ubuntu system.
I download the file 2014-09-09-wheezy-raspbian.zip
Unzip the file and open distutil on MAC system.
Find the 16 GB disk and clean that with MS-DOS(FAT) format.
Open command line and type
> diskutil list
Unmount the disk first
> sudo diskutil unmount /dev/disk2s1
Write the file to the disk
> sudo dd if=2014-09-09-wheezy-raspbian.img of=/dev/disk2 bs=2m
Type the username and password, pi, raspberry.
I change the password and add one user for myself.
>adduser carl
Add sudoer
>visudo
root ALL=(ALL:ALL) ALL
carl ALL=(ALL:ALL) ALL
ctrl + X to exit.
Set up the static ip
> cat /etc/network/interfaces
auto lo
iface lo inet loopback
#iface eth0 inet dhcp
iface eth0 inet static
address 192.168.0.106
gateway 192.168.0.1
netmask 255.255.255.0
dns-nameservers 8.8.8.8 8.8.4.4
allow-hotplug wlan0
iface wlan0 inet manual
wpa-roam /etc/wpa_supplicant/wpa_supplicant.conf
iface lo inet loopback
#iface eth0 inet dhcp
iface eth0 inet static
address 192.168.0.106
gateway 192.168.0.1
netmask 255.255.255.0
dns-nameservers 8.8.8.8 8.8.4.4
allow-hotplug wlan0
iface wlan0 inet manual
wpa-roam /etc/wpa_supplicant/wpa_supplicant.conf
iface default inet dhcp
Restart the system
> sudo reboot
Set up nodeJS env on raspberry pi.
Unzip the file and go to the working directory
> ./configure --prefix=/home/carl/tool/node-v0.10.33
>make
>make install
It will take a great long time to compile the source codes on that small machine. I may choose this one http://node-arm.herokuapp.com
Or I can download the arm-pi.tar.gz from some URLs like this http://nodejs.org/dist/v0.11.9/.
I pick up to install v0.10.28 or v0.11.11. Let me start with the latest one.
Some discussion about “ Illegal instruction"
Finally I found this version is working on my raspberry pi B+. http://nodejs.org/dist/v0.10.28/
> node -v && npm --version
v0.10.28
v0.10.28
1.4.9
Set up nginx on raspberry pi
Download and try with version 1.6.2, unzip the file and try to build that
> ./configure --prefix=/home/carl/tool/nginx-1.6.2
Configure not pass, I need to install this first
This command will help
> ./configure --prefix=/home/carl/tool/nginx-1.6.2 --with-pcre=/home/carl/tool/commons/pcre-8.36
It does not work well with manually installing PCRE. I may use this command to install PCRE instead.
> sudo apt-get install libpcre3
> sudo apt-get install libpcre3-dev
Command to test the config file
> sudo sbin/nginx -t
Command to start
> sudo sbin/nginx
Command to restart
> sudo sbin/nginx -s reload
Command to stop
> sudo sbin/nginx -s stop
References:
nginx installation
相关推荐
You'll also learn how programming works and how the operating system relates to the Raspberry Pi's physical components. Co-authored by Eben Upton, one of the creators of the Raspberry Pi, this is a ...
You’ll also learn how programming works and how the operating system relates to the Raspberry Pi’s physical components. Co-authored by Eben Upton, one of the creators of the Raspberry Pi, this is ...
You'll work with Linux driver information and explore the different Raspberry Pi models, including the Pi Zero, Pi Zero W, Pi 2, Pi3 B and Pi3 B+. You'll also review a variety of project examples ...
Set up your Raspberry Pi Zero with the operating system, networking, and different interfaces Get a hands-on introduction to Linux, Python, and shell scripts with the Raspberry Pi Zero Become a master...
With millions of new users and several new models, the Raspberry Pi ecosystem continues to expand—along with a lot of new questions about the Pi’s capabilities. The second edition of this popular ...
Understand how to initially download the operating system and set up Raspberry Pi Zero Find out how to control the GPIO pins of Raspberry Pi Zero to control LED circuits Get to grips with adding ...
Debian Linux operating system built specifically for the Raspberry Pi. This distribution contains all the Software Development Kits (SDKs) including one for Python that includes PyGame. If you don’t ...
介绍Raspberry Pi 4的用户手册,值得一读。 In our opinion, you will certainly adore the Raspberry Pi 4. Ultra-small, affordable, even cheaper than most video games, you can use the Pi to build ...
CHAPTER 1: INTRODUCTION TO RASPBERRY PI THE EVOLUTION OF RASPBERRY PI 2 THE UNIQUE FEATURES: MODEL A MODEL A+ MODEL B MODEL B+ SHOULD YOU BUY THE LATEST RASPBERRY PI 2, IF YOU HAVE PREVIOUS MODELS? ...
Raspberry Pi的ArchLinux SD映像这是一个SD卡映像,适合在Windows下使用Win32DiskImager直接映像到SD卡。 ArchLinux停止为Raspberry Pi生成现成的SD映像,但仍在以下位置提供根文件结构的可下载tarball:...
Set up and manage your Raspberry Pi Connect the Pi to a network Work with its Linux-based operating system Use the Pi’s ready-made software Program Raspberry Pi with Python Control hardware through ...
This book contains recipes that take advantage of the power and features of the ...Raspbian Linux operating system and the advanced networking solutions that are availablefor the Raspberry Pi today.
Leverage your Arduino skills in the Raspberry Pi world and see how to cross the two platforms into sophisticated programs. The Arduino and Raspberry Pi communities overlap more than you might ...
Learn about the Raspberry Pi 2 architecture and Raspbian operating system through innovative projects Book Description With the release of the Raspberry Pi 2, a new series of the popular compact ...
Wiley Learning Python with Raspberry Pi 2014年版
Install Raspbian, the operating system that drives the Raspberry Pi Drive motors through an I2C motor controller Read data through sensors attached to an Arduino Who This Book Is For Hobbyists and...
RaspberryPi的各种NodeJS绑定 正在安装 该项目已发布在! 这仅适用于RaspberryPi并安装了VideoCore固件! npm install raspberrypi 当前绑定 OpenMAX的 播放h264视频 显示JPEG图像 原料药 图片 displayImage...
Starting with an introduction to the Raspberry Pi and Arduino boards you will set up your very own home automation system through a series of exciting projects, making your life a lot easier. ...
Chapter 1: Meet the Raspberry Pi Chapter 2: Getting Started with the Raspberry Pi Chapter 3: Linux System Administration Chapter 4: Troubleshooting Chapter 5: Network Configuration Chapter 6: The ...
树莓派系统下载链接:https://pan.baidu.com/s/1OTbGP51r8GwZIGjsm-EZwA,提取码:d90x