文本版|topic 高级搜索
   名人堂 帮助 论坛制度 意见反馈 | 首页 博客 周新贴 专题 求职 读书
RSS 底部
 
社区导航: 专家门诊   网络技术   操作系统   数据库   程序设计   系统应用   考试认证   CIO及信息化   站长交流   综合交流   下载基地  51CTO产品服务 设为首页 | 收藏本站
51CTO技术论坛» Solaris & BSD & Unix » 在FreeBSD上安装Oracle教程       [ 打印]  [ 订阅]  [ 收藏]  [ 推荐给朋友]   [ 本帖文本页]

论坛跳转:
     
标题: [转载] 在FreeBSD上安装Oracle教程  ( 查看:1142  回复:4 )   
 
wantin6
高级工程师  点击可查看详细



帖子 1209
精华 7
无忧币 16024
积分 13314
阅读权限 70
注册日期 2005-9-23
最后登录 2008-6-1 离线

[查看资料]  [发短消息]  [Blog
       
发表于:2006-8-5 23:27   标题:在FreeBSD上安装Oracle教程
上一帖 |
源地址:http://ezine.daemonnews.org/200402/oracle.html

Installing Oracle9i on FreeBSD
Brian C. Ledbetter,
DISCLAIMER
Before We Begin
Step 1: Prerequisites
Step 2: Getting Oracle9i for Linux Distribution
Step 3: Preparing The Installation Process
Create /compat/linux/etc/mtab
Symlink /bin/awk, /bin/sed, /sbin/chown
Create /compat/linux/bin/arch
Configure SYSV Shared Memory
Step 4: Creating the Appropriate User Accounts
Step 5: Running the Installer
Step 6: Oracle Universal Installer
Step 7: Starting the Database
Appendix A: Credits
Appendix B: References
Appendix C: System as Tested
Appendix D: De-Installing Oracle
Appendix E: Revision History

--------------------------------------------------------------------------------

Disclaimer
This document is here for informational purposes only. Because Oracle will not support running their products on FreeBSD, if you choose to do so, you will be operating outside of the scope of their Professional Services and Support team, and will get no help from them if something goes wrong. If you are only interested in using the Linux version of Oracle9i for educational or testing purposes, just be aware that things might not work exactly as planned, and you just might lose all of your data. In any event, I cannot be held responsible for anything which might occur as a result of these instructions, and cannot stress enough that until such time as Oracle releases a native FreeBSD version of their products, you should never use this as a production system!

Neither BRIAN C. LEDBETTER, nor ORACLE CORPORATION claim any inherent responsibility with regard to the accuracy of the data contained within. All installations based upon these instructions are considered unsupported by ORACLE CORPORATION, and any damages caused by following these instructions may not be attributed to the information contained within. By following these instructions, you implicitly agree that you are doing so at your own risk, and accept the risks contained in performing this procedure.

Before We Begin
In the process of poking and prodding Oracle, I have devised a somewhat straight-forward (or, as close as I could get) installation procedure for running Oracle on Intel-based FreeBSD systems. By following these steps, you will end up with a working Oracle database installation, which should be safe for you to use for any kind of development purposes. I tested my database by installing the Oracle Marvel product (now called HTMLDB) into the instance - everything worked fine. Many people on the freebsd-database mailing list have accomplished this task before I did. My goal here is simply to consolidate all of the excellent advice passed to me from the list into an easy-to-follow guide. Full credit will be listed below to those who helped me in my quest to bring the World's Best Database to the World's Best Operating System. It is also worth noting that my examples are for installing an Oracle 9i Database, not the entire Oracle9i Application Server suite. The instructions will be somewhat different for a 9iAS installation, due to the complexity of that product. I may provide instructions for installing 9iAS at a later date, if I can get 9iAS to work correctly.

Step 1: Prerequisites
Oracle9i requires certain features to be installed on your system before it will run. For instance, in order for the automated binary relinking tools to run, you must have Linux versions of ld and gcc installed. It is also a requirement that your system be running at least FreeBSD 5.0-RELEASE. It is advised that the following ports/packages are mandatory, and should be installed before continuing:

emulators/linux_base
java/linux-sun-jdk13
devel/linux_devtools-7
Step 2: Getting Oracle9i for Linux Distribution
Oracle has made the Linux version of their products available for download under the condition that the product not be used in a production environment unless it is purchased and licensed for production use. Because we can't guarantee that Oracle on FreeBSD will be stable enough for a production environment (even though I think it would work ok, there is no need to take unnecessary risks with your enterprise's data), this should not pose a problem. You may sign up for an Oracle Technology Network account to download the software at otn.oracle.com. Pull down the software you wish to install (for instance, Oracle 9i Database, or Oracle 9i Application Server) and unpack the files into a staging directory.

  bsdbox# mkdir -p /u01/stage /u01/app/oracle /u02/oradata
  bsdbox# cd /u01/stage
  bsdbox# gzcat /path/to/lnx_920_disk1.cpio.gz | cpio -idmv
  bsdbox# gzcat /path/to/lnx_920_disk2.cpio.gz | cpio -idmv
  bsdbox# gzcat /path/to/lnx_920_disk3.cpio.gz | cpio -idmv
Step 3: Preparing the Installation Process
You will need to make adequate disk space available for Oracle to run on. In an ideal production environment, you would allocate space from a SAN or RAID disk array for the various Oracle-recommended directories (/u01, /u02, etc). Because we're not able to be a supported production environment, you probably don't need to worry too heavily about this - you just need to make enough disk space available for Oracle to run in. I recommend having at least 3 gigabytes of space available for Oracle Database to use, with another 2 gigabytes for data files.

Because of the plethora of differences between Linux and FreeBSD, there are a significant number of workarounds which must be performed in order for this procedure to succeed. Here is a list of what I have found necessary:

Create /compat/linux/etc/mtab
    bsdbox# cat /etc/fstab | grep -v '^#' | grep -v cd9660 | \
      grep -v proc | grep -v swap | grep -v devfs > \
      /compat/linux/etc/mtab
    bsdbox# cat /compat/linux/etc/mtab
    /dev/ad0s2a /      ufs rw 1 1
    /dev/ad1s1  /u01   ufs rw 1 1
Symbolically link awk, sed, and chown into /compat/linux/bin
While this isn't as elegant as a patch, it's much easier for us to deal with. The patch method will still work, but I don't have the time or desire to hunt down all of the Linux-specific references in Oracle's scripts.
    bsdbox# ln -s /usr/bin/awk /compat/linux/bin/awk
    bsdbox# ln -s /usr/bin/sed /compat/linux/bin/sed
    bsdbox# ln -s /usr/sbin/chown /compat/linux/sbin/chown
Create /compat/linux/bin/arch
    bsdbox# cat > /compat/linux/bin/arch
    #!/compat/linux/bin/bash
    echo i686
    ^D
    bsdbox# chmod +x /compat/linux/bin/arch
Configure SYSV Shared Memory and Semaphores
Oracle consumes quite a bit of memory whilst communicating amongst its many processes. Please refer to the Oracle Installation Guide for UNIX to determine the appropriate tuning values for your environment. You will need to build yourself a kernel with some additional parameters in order to make this work. Here is an example, which will build an Oracle-enabled GENERIC kernel. You would probably want to tune the kernel config file to suit your system's configuration. Please refer to Section 9 of the FreeBSD Handbook for details on configuring your kernel.
    bsdbox# cd /usr/src/sys/i386/conf
    bsdbox# cp GENERIC ORACLE
    bsdbox# cat >> ORACLE
    options         SEMMAP=128
    options         SEMMNI=128
    options         SEMMNS=32000
    options         SEMOPM=250
    options         SEMMSL=250
    options         SHMMAXPGS=65536
    options         SHMMAX=1073741824
    options         SHMMNI=4096
    options         SHMSEG=4096
    options         MAXDSIZ="(1024*1024*1024)"
    options         MAXSSIZ="(1024*1024*1024)"
    options         DFLDSIZ="(1024*1024*1024)"
    ^D
    bsdbox# config ORACLE
    Kernel build directory is ../compile/ORACLE
    Don't forget to do a ``make depend''
    bsdbox# cd ../compile/ORACLE
    bsdbox# make depend install
    [build output]
    bsdbox# reboot
    [system reboots]

__________________________________
2006-8-5 23:271楼
[ 顶部 ]
 
cnaix
新新人类  点击可查看详细



帖子 4
精华 0
无忧币 -2
积分 14
阅读权限 20
注册日期 2006-11-29
最后登录 2006-12-4 离线

[查看资料]  [发短消息]  [Blog
       
发表于:2006-11-29 18:53 
成功了吗?
2006-11-29 18:532楼
[ 顶部 ]
 
shzhang
技术员  点击可查看详细



帖子 147
精华 0
无忧币 830
积分 389
阅读权限 30
注册日期 2006-6-6
最后登录 2007-1-24 离线

[查看资料]  [发短消息]  [Blog
       
发表于:2006-11-29 21:02 
谢谢楼主!测试通过了吗?
2006-11-29 21:023楼
[ 顶部 ]
 
为人民服务
技术员  点击可查看详细



十二生肖之鸡   白羊座   行业勋章   技术勋章   诚信兄弟  
帖子 119
精华 0
无忧币 573
积分 241
阅读权限 30
来自 (保密)
注册日期 2006-11-24
最后登录 2008-10-27 离线

[查看资料]  [发短消息]  [Blog
  QQ       
发表于:2006-12-21 16:12 
?????????????????
2006-12-21 16:124楼
[ 顶部 ]
 
yateshi
新新人类  点击可查看详细



帖子 71
精华 0
无忧币 2
积分 71
阅读权限 20
注册日期 2007-8-18
最后登录 2007-9-16 离线

[查看资料]  [发短消息]  [Blog
       
发表于:2007-8-18 14:37 
dddddddddd



边测边学DB2,把握数据库应用最前沿(豪华大礼:罗技炫酷键鼠、50份卓越礼卡!)
2007-8-18 14:375楼
[ 顶部 ]
     
论坛跳转:  

| | |

| | |

| | |

标记已读 · 删除论坛Cookies · 文本版 · WAP
 
| 诚征版主 | 版主堂 | 意见建议 | 大史记 | 论坛地图
Copyright©2005-2008 51CTO.COM  Powered by Discuz!
本论坛言论纯属发布者个人意见,不代表51CTO网站立场!如有疑义,请与管理员联系。
京ICP备05051492号