Driver FixRecommendedSound, Wi-Fi or graphics acting up? Check drivers firstFind missing or outdated drivers fast.Check DriversOctober DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsSlow PC?RecommendedPC slow today? Run a repair scan before it gets worseResolve common Windows issues and optimize system performance.Scan Now×
Skip to content
VGSources
Blog

How to Install an SVN Server on Ubuntu

A complete Ubuntu guide to installing Subversion, configuring native svnserve or Apache mod_dav_svn, securing access, testing clients, and troubleshooting common failures.
Length9 min Posted Quest giverVGSources Team
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

The quickest Ubuntu setup is native svnserve: install Subversion, create a repository, configure authentication and path authorization, then start svnserve with the repository directory as its root. Use Apache httpd with mod_dav_svn instead when you need HTTP(S), existing Apache authentication, or several repositories behind one URL. The steps below cover both choices, with secure defaults and client tests.

Choose the server method before installing

Subversion repositories can be served by two different processes. Native svnserve speaks Subversion’s own svn:// protocol and is small and direct. Apache httpd with mod_dav_svn exposes repositories through WebDAV, normally at an http:// or https:// URL.

As an Amazon Associate I earn from qualifying purchases.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Consideration Native svnserve Apache/mod_dav_svn
Client URL svn://server/repository http://server/svn/repository or https://server/svn/repository
Transport Subversion custom protocol HTTP/WebDAV
Authentication Repository passwd and authz files, or a global configuration file Apache authentication modules, such as a password file, plus Subversion path authorization when configured
TLS Not provided by the basic svnserve setup described here Use Apache HTTPS after configuring TLS
Firewall exposure Usually TCP 3690, unless you select another port Use the web server’s existing HTTP/HTTPS ports
Best fit A controlled network with a simple, dedicated Subversion service Internet-facing access, existing web infrastructure, centralized authentication, or multiple repositories under one URL

For a private office or development network, svnserve has fewer moving parts. For access across untrusted networks, prefer Apache over HTTPS so credentials and repository traffic are protected by TLS.

Requirements and initial checks

  • An Ubuntu machine that remains reachable by your Subversion clients.
  • An account with sudo privileges.
  • A planned repository location, such as /srv/svn.
  • A DNS name or fixed address that clients can resolve.
  • A firewall policy that permits only the port and source addresses your users need.

Check the Ubuntu release before installing. Package revisions change over time; the Noble package identified in the Ubuntu manpage at one point was Subversion 1.14.3-1build4, but you should verify the version in your own release rather than assuming that number applies.

#1 Best Overall
Elebase USB to USB C Adapter for iPhone 18 Pro Max,USBC Car Charger Adapter | 4Pack Type C Female to A Male Cable Converter for Apple Duo 17 16 15 14 Plus,iWatch Watch 12 11 10,iPad 9 8 Air,Airpods 5 4
  • Read Before You Buy — No Video Output: These adapters support charging and USB 2.0 data transfer, but cannot transmit video signals. Except for standard USB webcams (which use USB data only), they are not compatible with HDMI/DisplayPort cables, video-capable USB-C hubs, or docking stations with video output.
  • Convert USB-A Ports to USB-C: Designed to connect USB-C earphones, cables, flash drives, card readers, and other USB-C accessories to standard USB-A ports. Plug-and-play with no drivers or software required.
  • Aluminum Alloy Housing: Built with a sturdy aluminum alloy shell that aids in heat dissipation and protects against daily wear and scratches. Designed to maintain a stable and secure connection.
  • Compact & Travel-Friendly: The ultra-compact design allows the adapter to stay plugged into your device without blocking adjacent ports or adding bulk, reducing wear and tear on your original USB ports.
  • 12-Month Warranty: Backed by a 12-month manufacturer warranty for peace of mind. Designed to meet strict quality control standards for reliable everyday performance.

Install Subversion on Ubuntu

  1. Refresh APT metadata:
    sudo apt update
  2. Install the native client and server package:
    sudo apt install subversion
  3. Confirm the installed build and available client commands:
    svn --version

Ubuntu’s subversion package includes svnserve. You do not install a separate native-server package. If you select Apache, install Apache httpd and the Ubuntu integration package that provides mod_dav_svn; on releases that use the conventional package naming, that is commonly:

sudo apt install apache2 libapache2-mod-svn

Package names can differ between Ubuntu releases, so confirm that the package is available on the target release before proceeding. The native and Apache methods are alternatives: install the Apache integration only when you intend to serve the repository through Apache.

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Create the repository safely

Keep repositories outside a user’s home directory and use a directory dedicated to Subversion. The following creates a parent directory with restrictive permissions and the conventional subversion group:

sudo install -d -m 0750 -o root -g subversion /srv/svn
sudo svnadmin create /srv/svn/myrepo

svnadmin create initializes the repository database; it does not create a working copy. The repository now has a conf directory for server settings, a hooks directory, and the internal database directories that Subversion manages.

Most teams organize project content with three top-level directories:

Rank #2
Sale
Anker USB-C Hub, 5-in-1 USB Hub for Laptops, 4K HDMI Multiport Adapter
  • 5-in-1 USB-C Hub: Experience comprehensive connectivity featuring a Power Delivery input, two USB-A 2.0 ports, a USB-A 3.0 port, and an HDMI port. (Note: The USB-C power delivery input port is only for connecting an external wall charger to power your laptop and cannot power peripheral devices.)
  • 90W Pass-Through Charging: Achieve optimal charging with 90W pass-through power to your laptop, supported by a total input of 100W, with the hub reserving 10W for operational efficiency. (Note: Wall charger not included.)
  • Quick Data Transfers: Accelerate your productivity with rapid data transfers using a high-speed 5Gbps USB 3.0 port and two 480Mbps USB 2.0 ports.
  • 4K HDMI Display: Enhance your visual experience with a hub capable of delivering 4K resolution at 30Hz in both mirror and extend modes. Please note that this hub is compatible with MacBook (macOS 12 and newer), Windows 10 and 11, ChromeOS, and laptops equipped with DP Alt Mode and Power Delivery. Note: This device is not compatible with Linux.
  • What You Get: Anker USB-C Hub (5-in-1, 4K HDMI), welcome guide, 18-month warranty, and our friendly customer service.
trunk/
branches/
tags/

This layout is a convention rather than a server requirement. Create it by importing an initial directory tree from a client, then check out trunk for normal development. Do not manually edit files inside the repository’s internal database directories.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Configure native svnserve authentication and authorization

Edit svnserve.conf

Open the configuration file for this repository:

sudo editor /srv/svn/myrepo/conf/svnserve.conf

Use this secure baseline:

[general]
anon-access = none
auth-access = write
password-db = passwd
authz-db = authz
realm = My Ubuntu SVN Repository

Remove leading whitespace from these settings. The Subversion configuration format is whitespace-sensitive in common Ubuntu examples; an indented key can be ignored or fail to behave as intended. anon-access = none prevents unauthenticated reads, while auth-access = write allows authenticated users to perform the operations granted by authz.

The repository-specific configuration is read from /srv/svn/myrepo/conf/svnserve.conf. A server started with a global --config-file can use another configuration source, so check the command line if changes to this file appear to have no effect.

Create users in passwd

Edit the password database referenced above:

sudo editor /srv/svn/myrepo/conf/passwd

Add users under the [users] section:

[users]
alice = replace-with-a-long-password

Replace the example value with a unique, long password. The file is part of the repository’s server configuration, so protect its filesystem permissions and limit shell access to administrators. Add one line per account; do not share one credential among an entire team.

Grant only the paths each user needs

Edit the authorization file:

sudo editor /srv/svn/myrepo/conf/authz

A minimal, deny-by-default policy is:

[groups]
developers = alice

[/]
@developers = rw
* =

The developers group receives read and write access to the repository root. The wildcard rule denies everyone else. You can grant separate permissions to subdirectories, for example:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #3
Sale
Anker USB C Hub, 7in1 Multi-Port USB Adapter, 4K@60Hz USBC to HDMI Splitter | 85W Max PD, 2 USB 3.0 & 1 USBC Data Ports, SD/TF Card Reader, for Laptops/Mac and Other Type C Devices (Charger Not Included)
  • Sleek 7-in-1 USB-C Hub: Features an HDMI port, two USB-A 3.0 ports, and a USB-C data port, each providing 5Gbps transfer speeds. It also includes a USB-C PD input port for charging up to 100W and dual SD and TF card slots, all in a compact design.
  • Flawless 4K@60Hz Video with HDMI: Delivers exceptional clarity and smoothness with its 4K@60Hz HDMI port, making it ideal for high-definition presentations and entertainment. (Note: Only the HDMI port supports video projection; the USB-C port is for data transfer only.)
  • Double Up on Efficiency: The two USB-A 3.0 ports and a USB-C port support a fast 5Gbps data rate, significantly boosting your transfer speeds and improving productivity.
  • Fast and Reliable 85W Charging: Offers high-capacity, speedy charging for laptops up to 85W, so you spend less time tethered to an outlet and more time being productive.
  • What You Get: Anker USB-C Hub (7-in-1), welcome guide, 18-month warranty, and our friendly customer service.
[groups]
developers = alice
reviewers = bob

[/]
@developers = rw
@reviewers = r
* =

[/myrepo/trunk/release]
@developers = rw
@reviewers = r

Keep path rules as narrow as your workflow permits. Test both a permitted path and a path that should be denied; a syntactically valid file can still grant more access than intended if a broad rule appears first or a group contains the wrong account.

Start svnserve and expose only the repository root

Start the native server with the parent directory as its root:

sudo svnserve -d -r /srv/svn

The -r /srv/svn option means clients address myrepo without learning the server’s full filesystem path. In daemon mode, svnserve listens on TCP port 3690 by default. Select a different port with --listen-port, or bind to a specific interface with --listen-host when the server has more than one network.

For a temporary diagnostic run that keeps the process in the foreground, use:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
sudo svnserve -d --foreground -r /srv/svn

Foreground mode makes startup errors visible in the terminal. Once the configuration works, arrange for the command to be launched by the host’s service manager at boot, and ensure that the account running it can read the repository and write transaction data. Do not assume that a manually started root process is an appropriate production service identity.

Rank #4
Sale
UGREEN USB to USB C Adapter Combo 4-Pack, 10Gbps USB C Converter Space Gray
  • Dual Converters, Infinite Potential:Includes 2× USB C male to USB A female adapters and 2× USB A male to USB C female adapters. Perfect for a wide range of uses—tablets with Bluetooth keyboards, expand USB ports on macbook, and more. Two different converters for all your daily needs
  • Next-Level 10Gbps & 3A Charging: No more slow 480Mbps, this usb to usb c adapter has a transfer speed of up to 10Gbps, allowing you to do more transferring in less time. This usb adapter fits both USB A and USB C charger, supporting up to 3A fast charging
  • Upgraded Exquisite Craftsmanship: With an aluminum alloy housing and metal connector, the usbc to usb adapter is extremely durable and sturdy. Rigorously tested to withstand more than 10,000 times of plugging and unplugging, ensuring long-lasting performance
  • Broad Compatible: The usb c to usb adapter widely supports all USB C/ USB A devices like laptops, tablets, cellphones, car chargers, and phone chargers. Such as compatible with MacBook Pro/Air 2023/2022, Thunderbolt 4/3 Devices,Apple MagSafe Watch 9/8/7/SE/Ultra, iPad Pro 2022/2021, Samsung Galaxy S23/S20/S10, and iPhone 17/16/15 Pro. Plug and play
  • Please Note: To reach 10Gbps speed, keep the cable under 3.3 ft. For USB A Male to USB C adapters, try flipping the USB C connector. USB C Male to USB A adapters support bidirectional 10Gbps transfer within 3.3 ft

Test the server from a client

Testing from another machine catches firewall, DNS, authentication, and permission errors that a local filesystem check cannot reveal.

  1. List the repository as the configured user:
    svn ls svn://server.example/myrepo --username alice
  2. Check out the development path:
    svn checkout svn://server.example/myrepo/trunk working-copy --username alice
  3. Create or edit a file in working-copy, then commit it and confirm that the revision appears in a second checkout.
  4. Repeat the test with an account that should be denied. It should not be able to list or modify paths excluded by authz.

Use the exact host name clients will use in production. A successful checkout from localhost does not prove that DNS, routing, or firewall rules are correct for remote users.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Serve the repository through Apache instead

Apache is the better fit when users already authenticate through a web server, when several repositories should share one URL prefix, or when clients need HTTPS. The repository remains on disk; Apache and mod_dav_svn provide the HTTP/WebDAV transport.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Install and enable the Apache integration

Install Apache and the package that supplies mod_dav_svn, then enable the WebDAV/Subversion modules required by your Ubuntu release. Confirm that Apache starts cleanly before adding the repository location. If you already run a web site, place the Subversion directives in the appropriate virtual-host configuration rather than exposing a second ad-hoc server.

Configure one or many repositories

For multiple repositories below one directory, use a location similar to:

Best Value
Sale
Anker USB C Hub, 5-in-1 USBC to HDMI Splitter with 4K Display | 85W Max PD, 1 Powered USB-C 5Gbps & 2 Powered USB-A 3.0 5Gbps Data Ports, for MacBook Pro, MacBook Air, Dell and More (Black)
  • 5-in-1 Connectivity: Equipped with a 4K HDMI port, a 5 Gbps USB-C data port, two 5 Gbps USB-A ports, and a USB C 100W PD-IN port. Note: The USB C 100W PD-IN port supports only charging and does not support data transfer devices such as headphones or speakers.
  • Powerful Pass-Through Charging: Supports up to 85W pass-through charging so you can power up your laptop while you use the hub. Note: Pass-through charging requires a charger (not included). Note: To achieve full power for iPad, we recommend using a 45W wall charger.
  • Transfer Files in Seconds: Move files to and from your laptop at speeds of up to 5 Gbps via the USB-C and USB-A data ports. Note: The USB C 5Gbps Data port does not support video output.
  • HD Display: Connect to the HDMI port to stream or mirror content to an external monitor in resolutions of up to 4K@30Hz. Note: The USB-C ports do not support video output.
  • What You Get: Anker 332 USB-C Hub (5-in-1), welcome guide, our worry-free 18-month warranty, and friendly customer service.
<Location /svn>
    DAV svn
    SVNParentPath /srv/svn
    AuthType Basic
    AuthName "Subversion Repository"
    AuthUserFile /etc/subversion/passwd
    Require valid-user
</Location>

SVNParentPath tells Apache that each child directory, such as /srv/svn/myrepo, is a repository. For exactly one repository, use SVNPath /srv/svn/myrepo instead. Do not use both directives for the same location.

The example requires every request to authenticate against the Apache password file. Create that file with the Apache password utility, protect it from ordinary users, and add accounts for the people who need access. If you also need per-path permissions, retain Subversion authorization rules and test them through the HTTP URL.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Use HTTPS for untrusted networks

Configure a valid TLS certificate on Apache and use an https:// repository URL. Basic authentication sends credentials in a form that must be protected by TLS; do not publish an Internet-facing password-protected repository over plain HTTP. Restrict the web server’s access with its normal firewall and virtual-host controls.

Filesystem ownership and firewall checks

  • Identify the account that actually runs svnserve or Apache and verify that it can read the repository configuration and write repository transactions.
  • Keep passwd and authz readable only by the service and administrators.
  • For native access, allow TCP 3690 only from trusted client networks unless you deliberately selected another port.
  • For Apache access, expose only the HTTP/HTTPS ports required by the virtual host; prefer HTTPS for remote users.
  • Do not enable anonymous write access. If anonymous reads are acceptable on an internal network, make that an explicit policy decision rather than leaving the default unclear.

Back up and verify before production use

Back up the complete repository directory, including its configuration and hook files, and document how you would restore it to a new Ubuntu host. A backup that contains only a working copy is not a repository backup. Perform a test restore and then run a checkout against the restored repository before relying on the procedure.

Record the repository URL, the selected transport, the service account, firewall rules, administrator contacts, and the authorization policy. After upgrades, run svn --version, verify that the expected server process is listening, and repeat an authenticated checkout from a separate client.

Troubleshooting common failures

“Connection refused” or a timeout

  • Confirm that svnserve or Apache is running on the intended host.
  • Check that the server is listening on the expected interface and port. Native svnserve uses 3690 unless changed.
  • Check DNS resolution and the firewall on both the Ubuntu host and any upstream network.
  • For Apache, verify that the virtual host is enabled and that the client URL matches its <Location> path.

Authentication succeeds but access is denied

  • Check the exact repository and path spelling in authz.
  • Confirm that the username appears in the intended group.
  • Make sure the configuration keys have no leading whitespace and that the running server is using the repository’s configuration file.
  • Test a deliberately allowed path and a deliberately denied path from a separate client.

The server cannot open the repository

Inspect ownership and mode bits on /srv/svn, /srv/svn/myrepo, and every parent directory. The service account needs directory traversal permission and write access where Subversion records transactions. A repository created as root may need its ownership or group adjusted before a non-root service account can use it.

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Apache returns a configuration or DAV error

Confirm that the mod_dav_svn integration package and required Apache modules are installed and enabled, then validate the Apache configuration before reloading it. Check that SVNPath points to one repository and SVNParentPath points to the directory containing multiple repositories; using the wrong directive is a common cause of a valid repository appearing unavailable.

Which setup should you deploy?

Use native svnserve when the repository is limited to a controlled network and you want the smallest configuration: one package, repository-local authentication, an explicit svn:// URL, and a narrowly opened port. Use Apache when HTTPS, existing web authentication, standard web-server operations, or a common URL for several repositories matters more than minimality. In either case, disable anonymous writes, apply least-privilege path rules, verify remote access, and maintain a tested backup and restore procedure.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More quests from Patch Notes

  1. How to Set Up a RedM (RDR2) Server in 2026: License Key, txAdmin and server.cfg, Step by StepBlog11min
  2. Best RedM (RDR2) Server Hosting in 2026: Comparing Four Hosts on Slots, Memory and PriceBlog10min
  3. How to Host a Mindustry Server in 2026: server-release.jar, Port 6567 and the Commands That MatterBlog7min
Recommended PC Tool
Recommended PC Tool
PC Slower Than It Used to Be?Free scan - under a minute
Crashes, No Sound, or Screen Glitches?Free driver scan

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.