You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

26 lines
455 B

  1. #!/bin/sh /etc/rc.common
  2. START=50
  3. gen_odbcinst() {
  4. local inifile
  5. echo "[ODBC]"
  6. echo "Trace = off"
  7. echo "TraceFile ="
  8. for inifile in /etc/odbcinst.ini.d/*.ini; do
  9. cat "$inifile"
  10. done
  11. }
  12. start() {
  13. [ ! -d /tmp/etc ] && mkdir /tmp/etc
  14. gen_odbcinst > /tmp/etc/odbcinst.ini.new
  15. chmod 0644 /tmp/etc/odbcinst.ini.new
  16. [ -e /tmp/etc/odbcinst.ini ] && ( rm /tmp/etc/odbcinst.ini || return 1 )
  17. mv /tmp/etc/odbcinst.ini.new /tmp/etc/odbcinst.ini
  18. }