Ubuntu using Ramdisk for better performance and fast response
来源:互联网 发布:树莓派和单片机的区别 编辑:程序博客网 时间:2024/06/05 18:51
原文连接Ubuntu using Ramdisk for better performance and fast response
I have written a tutorial about speed up Ubuntu response time by optimizing the usage of swap area, and that’s avoiding swapping processes out of physical memory for as long as possible. Here’s another way usingramdisk
to get better performance and fast response for Ubuntu.
Ramdisk is part of system memory. Ubuntu by default uses a half of physical memory (RAM) as ramdisk, and it is mounted onto/dev/shm
, it can be used just like normal disk space (create files and folders and manipulate them with better performance rather if they were stored on the hard disk). If ramdisk uses more than a half of RAM, data will be moved into the swap space. If ramdisk uses less, the remaining can still do what RAM’s doing.
Set upper limit of ramdisk
As is said above, ramdisk by default can use a half of RAM. If you want to change the upper limit, follow the steps below:
1. Edit /etc/fstab by your favourate editor:
gksudo gedit /etc/fstab
2. Find this line and change to make it looks like this(add this line if not exist, and change 512M to what you like.):
tmpfs /dev/shm tmpfs defaults,size=512M 0 0
3. Reboot or re-mount/dev/shm
.
Mount /tmp onto ramdisk
To make it easy to use, you can mount a directory into/dev/shm
by following commands:
mkdir /dev/shm/tmpchmod 1777 /dev/shm/tmpmount --bind /dev/shm/tmp /tmp
- Ubuntu using Ramdisk for better performance and fast response
- Using Reflection and Expression to get Property with better performance.
- Using C# Yield for Readability and Performance
- General Guidelines for Better Performance
- Making a 2D game for iPhone/iPad and need better performance?
- weblogic server with Jrockit. Good for better performance
- CSS Selector Performance has changed! (For the better)
- performance for php and zend
- Using Data Dictionary and Dynamic Performance Views
- Ubuntu Hacks : Tips & Tools for Exploring, Using, and Tuning Linux
- OpenOCD - Using JLink For ubuntu and Windows 7(Cygwin)
- Indexing NULL table column values for fast SQL performance
- Indexing NULL table column values for fast SQL performance
- Structuring Data and Serivces for Application Performance
- Performance Considerations for Direct3D9 and WPF Interoperability
- ZFS: Performance Tuning for Scrubs and Resilvers
- Performance and Optimization For Mecanim[Unity]
- OReilly.Ubuntu.Hacks.Tips.and.Tools.for.Exploring.Using.and.Tuning.Linux.Jun.2006.eBook-BBL
- Struts2之单文件上传
- 懒加载
- 黑马程序员 —— Java高级视频_IO输入与输出(第十九天)2
- 如何安装Ubuntu14.04操作系统及Chromium浏览器、FlashPlayer插件
- hdu 1394 求逆序数(线段树求)
- Ubuntu using Ramdisk for better performance and fast response
- 招聘QT+opencv联合编程人员
- CashWithdraw
- 黑马程序员 —— Java高级视频_IO输入与输出(第二十天)
- HGE引擎---hgeAnimation动画精灵
- 黑马程序员 —— Java高级视频_IO输入与输出(第二十一天)
- MVC学习系列-表单的异步提交
- 如何使用online account来创建微博Scope
- 挂载cd,复制cd内容