Until recently, the cheapest product was the HP microserver Gen 8, it was available for less than PLN 900 and it had everything. We bought it in bulk, there was a wall in the company, friends bought it for home, I bought one myself as a backup via the main NASA rsync.
Cheaper, it comes out differently.
You can take a historic atom like Intel D945GSEJT, plus a PCI controller for PLN 40 on a silicon image chip. Put nas4free on it and you're done.
Such NAS rubbish, I also put together one in the company, it worked for 4 years ^^ (I was refused a new one, I pissed off and put together NAS rubbish, it was necessary when it fell, they bought a professional server).
Such a junk Atom N270 will easily pull out 1Gb / s and will not even ignite it.
Instead, you can go crazy with old procks like celerons on LGA1155, or pentiums, even some Linux VM, it will fall off a bit.
Worse with hardware controllers, despite their coolness, they are often products with poor support in linux, and even worse in freebsd.
Sometimes you have to flash the chip for it to work and it doesn't always work properly.
It's good to understand what you are buying.
On windows it is easier, when the motherboard accepts it, rather windows will handle it as it is supported, but at the cost of a greater demand for server power. Well, there is the issue of legality, or there is an option for Windows Core and a VM on it for various tasks, including as a server (I ignore how it is terribly handled), it is probably for free and I do not know if it will fire directory sharing, but I think so.
A better tier alternative is Proxmox, you will make samba and VM.
It's nice if the motherboard and CPU support ECC RAM, it makes it possible to use ZFS and brtfs with sense, you can do without it, but it's more for science. Because there isn't one of the foundations for these file systems.
The bonus is that the ECC DDR3 RAM is relatively cheap (brutally cheap), so when there is space, you can load it all the way.
What would I personally recommend, a CPU with ECC, supporting UEFI, preferably with a passtrough controller (i.e. disks seen in a system without RAID), as it will support SAS disks, is an additional plus, because those used are quite cheap, at the same time they are much more durable .
For learning and starting, it is just right, then if you want to transcode a video or VM, you can recharge what will not do for you. You will understand the construction and it will be ok.
Personally, I think that it is the most profitable to buy a Microserver G8 / G10, or this atom, it will last a long time, it will fly over the VM and support current technologies.
But when there is no money, it's difficult.
As for savings, I recommend ebay and china, for example I bought an intel x520-da1 with holograms and papers, for about PLN 250, it is already working for a long time, and for the same in Poland I would have to pay a thousand more.
The system is nas4free (on old age), freenas (for new server devices), proxmox as the purpose of virtualization, linux (whoever you prefer, because everything will be done on server matters), I prefer to keep windows in the VM, but one core as I also use the host VM, because the platform doesn't support Linux very well, and there is a herd of linux on it.