In the expanding Semantic Web, an increasing number of sources of data and knowledge are accessible by human and software agents. Sources may differ in granularity or completeness, and thus be complementary. Consequently, unlocking the full potential of the available knowledge requires combining them. To this aim, we define the task of knowledge reconciliation, which consists in identifying, within and across sources, equivalent, more specific, or similar units. This task can be challenging since knowledge units are heterogeneously represented in sources (e.g., in terms of vocabularies). In this paper, we propose a rule-based methodology for the reconciliation of $n$-ary relations. To alleviate the heterogeneity in representation, we rely on domain knowledge expressed by ontologies. We tested our method on the biomedical domain of pharmacogenomics by reconciling 50,435 $n$-ary relations from four different real-world sources, which highlighted noteworthy agreements and discrepancies within and across sources.