====== Distributions utilisées sur les machines du labo ====== depuis 2011, deux machines sont maintenues * antigone [[reserve:opensolaris|Solaris 11 Express]] (ex [[reserve:opensolaris]]) * fury Solaris 10 * Solaris 8 et 10 * [[http://opensolaris.org/os/downloads/|Solaris Express]] sur portables (dellgh) * [[reserve:Opensolaris]] (dite Indiana) sur ultra20 et portables delljm et dellcp * [[http://www.genunix.org|nexenta]] testée puis de-installée ====== Outils d'admin ====== * [[reserve:correctifs_pour_solaris|Correctifs pour Solaris]] * [[reserve:explorer|Explorer pour Solaris]] ====== Infodocs ====== * PDF en local [[file:///net/fury/donnees/provisoire/logiciels/solaris/47.16/Contents.html|Solaris 10 System Administrator Collection]] * [[http://blogs.sun.com/DanX/entry/solaris_ipv6_tunnel_setup|Solaris IPv6 tunnel setup]] * [[http://blogs.sun.com/toddjobson/|Performance and Capacity Planning]] * Gestion de ressources sous Solaris 10 [[http://daniel.polombo.fr/2008/03/gestion-de-ressources-sous-solaris-10/|Lien externe]], [[http://blogs.sun.com/robertlor/entry/virtualization_and_resource_management_in|Postgres and Solaris Virtualization]], [[http://forum.java.sun.com/thread.jspa?messageID=10171916&tstart=0|Solaris Zones - capped memory??]] * [[http://www.sun.com/bigadmin/content/submitted/swap_space_impact.jsp|le swap]] Impact of Swap Space on System Performance for the Solaris 9 and 10 OS * [[http://sunsolve.sun.com/search/document.do?assetkey=1-61-211624-1|Systems Performance Utilities References]] * [[http://blogs.sun.com/yongsun/entry/several_tips_of_porting_gnu]] pour les problèmes de compilation de logiciels gnu * outils pour rendre le code plus performant: * [[http://frsun.downloads.edgesuite.net/sun/08B01312/index.html|un outil]] permet d'optimiser une appli sans le source, un autre permet de trouver les problemes memoire (sorte de lint?) a voir si ca marche en fortran? **Discover** The Sun Memory Error Discovery Tool (Discover) is used by software developers to detect programming errors related to the allocation and use of program memory at runtime. * [[http://blogs.sun.com/hein/|Lien externe]] à voir, sur SRM, zfs, mémoire, ... * [[http://blogs.sun.com/timc/entry/comparison_of_some_sparc_v9|des comparaisons sur les procs sparc]] * [[http://developers.sun.com/solaris/articles/solaris_graphics.html|lancer un faux serveur Xvfb]], [[http://opensolaris.org/jive/thread.jspa?messageID=195697|xvfb on solaris 10]], [[http://forum.java.sun.com/thread.jspa?threadID=5098789&messageID=9339008|Servlet using Xvfb needs DISPLAY set]] * [[http://sunsite.uakom.sk/sunworldonline/common/swol-backissues-columns.html#sysadmin|des articles techniques solaris ]] ===== Ldap ===== * [[http://developers.sun.com/identity/reference/techart/ds-perl.html|Perl Scripts Offer Quick, Accurate Installation and Configuration of Sun Java System Directory Server]] ===== Sparc ===== * [[http://www.brandonhutchinson.com/Miscellaneous_Solaris_notes.html|Miscellaneous Solaris notes]] * [[http://prefetch.net/blog/index.php/2008/03/21/findingsetting-nvalias-nvram-obp-settings-from-a-running-solaris-os/|Finding/setting nvalias (nvram) OBP settings from a running Solaris O/S]] ====== Tips ====== ===== modifier grub dans opensolaris (boot zfs) ===== Avant le boot zfs, il suffisait de booter sur un cd, de monter la partition ufs contenant le /. Avec zfs, il faut récupérer le pool, et accéder à /rpool/boot/grub/menu.lst Lorsqu'on boote sur le LiveCD, on a: jack@opensolaris:~$ pfexec zpool import pool: rpool id: 7697179275706784463 state: ONLINE status: The pool was last accessed by another system. action: The pool can be imported using its name or numeric identifier and the '-f' flag. see: http://www.sun.com/msg/ZFS-8000-EY config: rpool ONLINE c3d0s0 ONLINE jack@opensolaris:~$ pfexec zpool import -f rpool cannot mount '/opt/jdsbld': failed to create mountpoint cannot mount '/usr/local': failed to create mountpoint jack@opensolaris:~$ zfs list NAME USED AVAIL REFER MOUNTPOINT rpool 17.7G 1.84G 50K /rpool rpool/ROOT 10.5G 1.84G 18K legacy rpool/ROOT/opensolaris 6.37M 1.84G 8.72G / rpool/ROOT/opensolaris-5 196M 1.84G 8.72G / rpool/ROOT/opensolaris-nv 10.3G 1.84G 8.72G / rpool/dump 511M 1.84G 511M - rpool/export 5.51G 1.84G 19K /export rpool/export/home 5.51G 1.84G 24.3M /export/home rpool/export/home/henry 5.49G 1.84G 5.49G /export/home/henry rpool/jdsbld 18K 1.84G 18K /opt/jdsbld rpool/local 719M 1.84G 719M /usr/local rpool/swap 557M 1.84G 557M - /rpool est donc directement accessible: jack@opensolaris:~$ cat /rpool/boot/grub/menu.lst splashimage /boot/grub/splash.xpm.gz background 215ECA timeout 30 default 3 #---------- ADDED BY BOOTADM - DO NOT EDIT ---------- #---------------------END BOOTADM-------------------- title Windows rootnoverify (hd0,0) chainloader +1 # Unknown partition of type 5 found on /dev/rdsk/c3d0p0 partition: 2 # It maps to the GRUB device: (hd0,1) . title opensolaris-5 findroot (pool_rpool,2,a) bootfs rpool/ROOT/opensolaris-5 kernel$ /platform/i86pc/kernel/$ISADIR/unix -B $ZFS-BOOTFS module$ /platform/i86pc/$ISADIR/boot_archive #============ End of LIBBE entry ============= title opensolaris findroot (pool_rpool,2,a) bootfs rpool/ROOT/opensolaris kernel$ /platform/i86pc/kernel/$ISADIR/unix -B $ZFS-BOOTFS module$ /platform/i86pc/$ISADIR/boot_archive #============ End of LIBBE entry ============= title opensolaris-nv findroot (pool_rpool,2,a) bootfs rpool/ROOT/opensolaris-nv kernel$ /platform/i86pc/kernel/$ISADIR/unix -B $ZFS-BOOTFS module$ /platform/i86pc/$ISADIR/boot_archive #============ End of LIBBE entry ============= par contre, pour accéder à passwd/shadow, il faut monter manuellement le dataset zfs correspondant. * http://wiki.genunix.org/wiki/index.php/ZFS_rpool_Upgrade_and_GRUB * http://www.sun.com/bigadmin/content/submitted/zfs_root_clone.jsp ===== Générer un core sur un kernel pour analyse ===== en cas de problème, et qu'on soit obligé de faire un ''break'' (STOP ), il vaut mieux générer un core du kernel pour analyse ultérieure à la hotline sun: sc> break -c Are you sure you want to send a break to the system [y/n]? y Enter SC Alert: SC Request to send Break to host. #. to return to ALOM. Debugging requested; hardware watchdog suspended. Type 'go' to resume {1b} ok sync panic[cpu27]/thread=2a101901cc0: sync initiated sched: software trap 0x7f pid=0, pc=0xf0246438, sp=0x2a101900ec1, tstate=0x4400001402, context=0x0 g1-g7: 10528d0, 1, 186c400, 0, 0, 0, 2a101901cc0 00000000fee79cd0 unix:sync_handler+144 (1822400, 1f, 0, 1, 1, 108d800) %l0-3: 0000000001856e88 000000000188f340 000000000188f000 000000000000017f %l4-7: 0000000001872c00 0000000000000000 000000000186c400 000000000000001f 00000000fee79da0 unix:vx_handler+80 (fee7b958, 182fed0, a, 1822400, 182ffd8, f025a159) %l0-3: 000000000182ffd8 0000000000000000 0000000000000001 0000000000000001 %l4-7: 0000000001822c00 00000000f0200000 0000000001000000 000000000101b59c 00000000fee79e50 unix:callback_handler+20 (fee7b958, f01221c0, 0, 0, 0, 0) %l0-3: 0000000000000016 00000000fee79701 00000000f0200000 00000000fff78000 %l4-7: 0000000001009008 0000000000000000 0000000000000000 00000000f01237f0 syncing file systems... done dumping to /dev/md/dsk/d1, offset 1718288384, content: kernel 5% done la commande sync déclenche le dump du kernel à l'endroit prévu ===== utilisation de snoop pour debuger un client dhcp ===== [[http://docs.sun.com/app/docs/doc/806-5529/6jehkcs8f?a=view|Troubleshooting DHCP Client Configuration Problems]] ===== autres outils ===== * [[http://www.informit.com/articles/printerfriendly.aspx?p=1161980|tools to assist in diagnosing and determining system configuration, development, and performance problems]], extrait du livre "Solaris Application Programming ===== réparer un mirroir SVM ===== * [[http://docs.sun.com/app/docs/doc/816-4520/6manpieqm?l=en&a=view|How to Recover a System Using a Solaris Volume Manager Configuration]] * [[http://sunsolve.sun.com/search/document.do?assetkey=1-62-202794-1|202794 : Solaris[TM] Volume Manager Software and Solstice DiskSuite[TM] Software: Mounting Metadevices ]] * [[http://sunsolve.sun.com/search/document.do?assetkey=1-61-207913-1|207913: Solstice DiskSuite[TM] software - Unable to boot from a DiskSuite-controlled system disk]] ---- ===== Anciennes notes ===== * [[http://www.cmi.univ-mrs.fr/UFR/intranet/reseau/solaris-tips.html]] ===== Sauver un fs en cours d'utilisation ===== à partir de fssnap: ufsdump 0f - /dev/fssnap/0 | gzip -c | ssh xxx 'cat - > /export/home/backup/server/rs790-zones.ufs.gz ===== Ajouter un menu dans gdm ===== * [[http://fluxbox.sourceforge.net/docs/en/faq.php#gdm|How do I add fluxbox to my GDM sessions menu]] * [[http://library.gnome.org/admin/gdm/stable/configuration.html.en|GNOME Display Manager Reference Manual]] * [[http://www.ezunix.org/index.php?title=Configure_automatic_login_on_Solaris_and_OpenSolaris_with_GDM|utilisation de .Xclient]] ====== Commandes pour changer la configuration du serveur X (Ultra5, 10, SB100) ====== m64config -propt # pour connaitre la configuration actuelle m64config -res \? # les configs possibles m64config -res 1024x768x76 -now # change la config Attention si la config choisie n'est pas supportee il faudra se logger a distance pour revenir a la config precedente m64config -depth 8 # pour changer la profondeur Autre commande: xdpyinfo (serveur X existe sur toutes les plateformes) fbconfig -list # pour connaitre la liste des devices graphiques. Par exemple sur une Ultra10 de base: Device-Filename Specific Config Program --------------- ----------------------- /dev/fbs/m640 SUNWm64_config ====== Une comparaison des outils entre Linux et Solaris ====== * [[http://bhami.com/rosetta.html|A Sysadmin's Unixersal Translator]] * [[http://www.cmi.univ-mrs.fr/UFR/intranet/reseau/admin.html|comparaison (old)]] ====== Outils de compilation ====== * voir la page [[calcul]] * voir [[http://solaris-x86.org/documents/guides/compile.mhtml|Compiling source code]] * [[reserve:problemes]] ====== SFE ====== * [[http://opensolaris.org/os/project/jds/contributing/building/#jds-build-solaris-packages|Building Solaris Packages]] ou [[http://sourceforge.net/apps/mediawiki/pkgbuild/index.php?title=Pkgbuild_on_OpenSolaris|Pkgbuild on OpenSolaris]] ===== spec files ===== on récupère les spec files de la communauté (contrib): "spec-files-extra is another repository, on sourceforge.net, for packages that are not available in OpenSolaris. http://pkgbuild.sourceforge.net/spec-files-extra/ It contains over 500 community contributed spec files!! http://pkgbuild.svn.sourceforge.net/viewvc/pkgbuild/spec-files-extra/trunk/" > svn co https://pkgbuild.svn.sourceforge.net/svnroot/pkgbuild/spec-files-extra/trunk SFE donc les SFExxx.spec sont dans le répertoire SFE, il y en a aussi dans le répertoire archive et voir [[http://mail.opensolaris.org/pipermail/belenix-discuss/attachments/20070805/2fb5ec9b/attachment-0001.odt|PKGTOOL_documentation.02.odt]] ou {{build_os_pkg_using_pkgbuild_pkgtool.pdf|local}}, et aussi [[http://www.opensolaris.org/jive/forum.jspa?forumID=39|Lien externe]] Les archives téléchargées sont dans le dossier /local/apps/packages/SOURCES/ (modifiable avec un .pkgtoolrc) ===== utilisation ===== > source /opt/dtbld/bin/env.csh > cd SFE/ > pkgtool build --download SFEfltk.spec INFO: Copying %use'd or %include'd spec files to SPECS directory INFO: Processing spec files INFO: Finding sources INFO: Downloading source http://ftp.easysw.com/pub/fltk/1.1.7/fltk-1.1.7-source.tar.bz2 INFO: Running pkgbuild -ba [...] SFEfltk.spec (SFEfltk) INFO: SFEfltk PASSED INFO: Installing SFEfltk INFO: Installing SFEfltk-devel Summary: package | status | details ---------------------------------+-------------+------------------------------- SFEfltk | PASSED | On peut vérifier dans /tmp/SFEfltk.log que tout s'est bien passé. \\ donc fltk est installé dans /: /usr/sbin/pkgchk -v SFEfltk NOTE: Couldn't lock the package database. /usr/bin /usr/bin/fluid /usr/lib /usr/lib/libfltk.so /usr/lib/libfltk.so.1.1 /usr/lib/libfltk_forms.so /usr/lib/libfltk_forms.so.1.1 /usr/lib/libfltk_gl.a /usr/lib/libfltk_gl.so /usr/lib/libfltk_gl.so.1.1 /usr/lib/libfltk_images.so /usr/lib/libfltk_images.so.1.1 /usr/share /usr/share/man /usr/share/man/man1 /usr/share/man/man1/fltk-config.1 /usr/share/man/man1/fluid.1 ===== creations de packages ===== on essaie avec le paquet Tix. * on crée le fichier SFEtix.spec dans ~/packages/SPECS * on le teste avec la commande: pkgtool -vv build-only SFEtix.spec * on regarde les logs: /local/apps/packages/LOGS/SFEtix.log * une fois compilé, on peut l'installer, le pkg est dans ~/packages/PKGS/ > pfexec pkgadd -d ~/packages/PKGS/SFEtix-8.4.3.i386.pkg Ne pas oublier pfexec! ===== le fichier .pkgtoolrc ===== ===== le fichier .pkgbuildmacros ===== s'il contient: devel1@nemo:~/src/SFE$ cat ~/.pkgbuildmacros %_basedir /local/apps/test1234 installra les packages dans /local/apps/test1234 (Attention, il faut sourcer ce fichier à chaque modif, en se reloggant par exemple) ====== SourceJuicer ====== * [[http://blogs.sun.com/jucr/entry/source_juicer_screencast|demo]] * [[http://blogs.sun.com/weber/entry/contribute_to_opensolaris_sourcejuicer|webcast]] * [[http://blogs.sun.com/simons/entry/how_to_contribute_a_package|Lien externe]] ====== SVM ====== SVM: Solaris Volume Manager, utilisé essentiellement pour faire du mirroir (RAID1 logiciel) ===== Avantages ===== ===== Inconvénients ===== en cas de problème, on ne peut pas réparer en single-user (FIXME), il faut casser le mirroir (modifier /etc/system et /etc/vfstab) ===== Ressources ===== * [[http://users.cs.fiu.edu/~tho01/psg/sol.html|Volume Management]]